﻿

How to run "Algo_Li_et_al_2019" in Igor Pro:

	1. Load data files into Igor Pro. (use function: LoadWave)

	2. Rename variables if necessary. In our code, the variables' name are: 
		reference absorption coefficient (e.g., from a Photoacoustic Extinctiometer): 		
			babs_red_ref,babs_green_ref,babs_blue_ref
		scattering coefficient (e.g., from a Nephelometer): 
			bscat_red,bscat_green,bscat_blue
		attenuation coefficient measured by the Filter-Based Absorption Photometer: 	
			batn_red,batn_green,batn_blue
		transmission measured by the Filter-Based Absorption Photometer: 
			Tr_red,Tr_green,Tr_blue

	3. Check if the time scale of filter-based batn is the same as that of bscat and reference babs.

	4. Run Algo_Li_et_al_2019(). 
		The function will automatically selecting the appropriate algorithm and implement it. 
		Major outputs will display in the commend window (e.g., Implement Algorithm A (or B, C), Loop No. 1, etc.).



Note:
1. In the current code of "Algorithm B", the initial coefficient values are set to be "FIREX-CLAP". Change the coefficient values if necessary. Recommended initial guesses for the other combinations of aerosol type and filter-based absorption photometer can be found in Table 4 in the manuscript.

2. We provide a sample dataset (FIREX_CLAP_sample_dataset.csv) in the folder for test purpose. Load the sample dataset and run "Algo_Li_et_al_2019". You should reproduce the FIREX-CLAP's coefficient values shown in Table 4 in the main text.

3. A version of code in Matlab is under consideration. Please contact us if you are interested in this.