Chih-Sheng Hsieh and Xu Lin, "Social Interactions and Social Preferences in Social Networks", Journal of Applied Econometrics, Vol. 36, No. 2, 2021, pp. 165-189. All files are ASCII files in DOS format. They are zipped in the file hl-files.zip. Unix/Linux users should use "unzip -l". PROGRAM FILES: The program files are provided for implementing the Monte Carlo simulation and the empirical study of the paper. Note that you also need the INTEL Math Kernel Library (MKL) to compile with the FORTRAN codes. An example command of compiling these files is ifort -mkl -nologo -openmp -O2 -o EST -I /opt/intel/composer_xe_2013_sp1.3.174/mkl/include/em64t/lp64 random.f90 tool.f90 model_I.f90 Under the folder "simulation", there are FORTRAN codes to generate Monte Carlo simulation results in Table 1 of the paper. - In the sub-folder "DGP", there are three FORTRAN 90 files and they should be complied together to form an executive file to generate artificial network and activity variable data. - In the sub-folder "estimation", compiling FORTRAN 90 file "model_I" with "random" and "tool" generates an executive file to estimate the Model (I). - In the sub-folder "estimation", compiling FORTRAN 90 file "model_II" with "random" and "tool" generates an executive file to estimate the Model (II). - In the sub-folder "estimation", compiling FORTRAN 90 file "model_III" with "random" and "tool" generates an executive file to estimate the Model (III). - In the sub-folder "estimation", compiling FORTRAN 90 file "model_IV" with "random" and "tool" generates an executive file to estimate the Model (IV). - In the sub-folder "estimation", compiling FORTRAN 90 file "model_V" with "random" and "tool" generates an executive file to estimate the Model (V). - "random" and "tool" are two modules which contain useful subrountines and functions Under the folder "empirical", there are STATA, and FORTRAN codes to prepare data and estimate models in Tables 3, 4 and Supplementary Appendix Tables C.3-C.6 of the paper. - In the sub-folder "data_preparation", the STATA file "read_AddHealth" reads the raw Add Health Wave-I in-school database and extracts the sample of 24 schools for the empirical analysis. - In the sub-folder "estimation/conventional_social_interactions_model", compiling FORTRAN 90 files "estimation_conventional_SAR" and "random" and "tool" generates an executive file to estimate Model (I) in Tables 3 & 4. - In the sub-folder "estimation/conventional_social_interactions_model", compiling FORTRAN 90 files "estimation_conventional_SAR_with_externality" and "random" and "tool" generates an executive file to estimate Model (III) in Tables 3 & 4. - In the sub-folder "estimation/altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_altruistic_SAR_exogenous_no_externality" with "random" and "tool" generates an executive file to estimate Model (II) in Tables 3 & 4. - In the sub-folder "estimation/altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_altruistic_SAR_exogenous" with "random" and "tool" generates an executive file to estimate Model (IV) in Tables 3 & 4. - In the sub-folder "estimation/altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_altruistic_SAR_endogenous" with "random" and "tool" generates an executive file to estimate Model (V) in Tables 3 & 4. - In the sub-folder "estimation/directed_altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_directed_altruistic_SAR_exogenous" with "random" and "tool" generates an executive file to estimate Directed Altruistic Model in Table C5. - In the sub-folder "estimation/directed_altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_directed_altruistic_SAR_exogenous_with_externality" with "random" and "tool" generates an executive file to estimate Directed Altruistic Model w/ externality in Appendix Table C5. - In the sub-folder "estimation/heterogeneous_altruistic_social_interactions_model", compiling FORTRAN 90 files "estimation_heterogeneous_altruistic_SAR" with "random" and "tool" generates an executive file to estimate the model in Appendix Table C6. - "random" and "tool" are two modules which contain useful subroutines and functions. - The results in Appendix Tables C.3-C.4 can be obtained by changing the latent variable dimensions in the FORTRAN file "estimation_altruistic_SAR_endogenous". DATA: The data used in the article are from the National Longitudinal Study of Adolescent to Adult Health (Add Health) WAVE I in-school survey data. This is a confidential data source administered by Add Health Carolina Population Center University of North Carolina at Chapel Hill CB# 8120, University Square 206 West Franklin Street Chapel Hill, NC 27516 Researchers should submit a research proposal to the above address to get permission to use these data. Please address any questions about the codes to: Chih-Sheng Hsieh cshshieh [AT] ntu.edu.tw Department of Economics National Taiwan University No.1, Sec 4, Roosevelt Road, Taipei, 10617 Taiwan