Some codes that I have used and developed are listed below.

AGN-Specfit

AGN-Specfit (AGN Spectral Fitting) is a modified version of QSFit. It is created as a pipeline to analyze SDSS Type 1 active galaxy optical and ultraviolet spectra. The prerequisites to run it are Python (version 2.7), IDL (version ≥ 8.1), and Gnuplot (version ≥ 5.0). To use the pipeline, you have to:

  1. Add SDSS spectra files to the “data” directory.
  2. Create a list of file names, redshifts, and E(B-V) and store it in the “QSO_name.csv” file.
  3. Create directories that are named:
    • “output” and “table” to store the calculations in the nested and flattened-structure files, respectively.
    • “plot” to save all the plot data and later be opened with the Gnuplot.
    • “result” to store the merged tables from the “table” folder.
  4. Start an IDL session in your working directory. Then, compile and run the IDL scripts:
     IDL> CD, "D:\path\where\AGN-Specfit\is\located"
     IDL> compile 
     IDL> process_spectra
    
  5. Use the Python scripts to combine all tables in the “table” folder into one concatenated table. You have to install the necessary modules first:
     pip install -r requirements.txt
     python multi_make_table.py
    
  6. You can specify which columns to keep by modifying the “result/columns_to_keep.txt” files.
  7. Edit the scripts if necessary to suit your needs.
AGN-specfit example
Example of spectral modeling by using AGN-Specfit for SDSS AGN data.

ANNZ for Photo-z

ANNZ is a public photometric redshift (photo-z) code that was originally developed by Sadeh et al. (2016). This code implements the artificial neural network, boosted regression trees, and other machine learning methods to estimate and generate photo-z probability distribution functions (PDFs). It also mitigates problems of non-representative or incomplete spectroscopic training samples by using a weighting scheme.

ANNz2
Example of photo-z caculation result compared to spectroscopic redshift values.

Here we utilize the code to estimate our AGNs photo-z and determine their luminosity function in our work regarding the Cosmic Evolution of Nearby Radio Active Galactic Nuclei. The forked and modified code is available for download at https://github.com/irhamta/ANNZ.

Code Repository

All of my codes are publicly available and maintained on my GitHub pages below.

coding

Link to GitHub