Thanks to visit codestin.com
Credit goes to github.com

Skip to content

karenlmasters/HaverfordGalaxyGroup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HaverfordGalaxyGroup

Code collaboration for the Galaxy Group at Haverford College.

Warning - this README is not automatic, so sometimes there's code here which is not documented/sorted corrected.

  • 1ADVICE.txt - advice to please read this README file!

Example Codes Either Written to help, or output of student papers

Basic Statistics/Coding Techniques

Working with MaNGA Data

Working with Galaxy Zoo

Working with Galaxy Zoo 3D Masks (and MaNGA Data)

Working with HI-MaNGA Data/HI Data

Other Useful Repositories

ASTR352 (Extragalactic Data Science Class) https://github.com/karenlmasters/ASTR352JupyterActivities

Masha's Spiral Arm Project Respository: https://github.com/mashakilibarda/Spiral_Arms_Mass_Project

Research Group Members also might like to check out Group Google Drive, which has some more private code sharing stuff.

David Stark's survival analysis code (https://github.com/dvstark/survival/tree/main)

Instructions for setting up an Conda environment for survival analysis codes

Note: These steps were performed using an Apply Macbook Pro with M1 processor and Sequoia 15.5

  1. Install R from here

  2. This may be optional, but here is how conda was set up in this working example:

    • Install miniconda. Anaconda is probably fine too, just takes longer.

    • Add conda-forge to the conda channels:

      >> conda config --add channels conda-forge
      
    • Install a few packages that improve conda's speed when solving environments, and improve how it handles packages installed via pip

      >> conda install -n base conda-libmamba-solver
      >> conda config --set solver libmamba
      >> conda config --set pip_interop_enabled true 
      
  3. Setup new conda environment w/ some standard packages. I called my environment rpy2. We're not actually installing rpy2 yet though. Conda-forge installs an older version that seems to force use of an older version of R that's incompatible with packages we need…

    >> conda create -n rpy2 python=3.12 jupyterlab numpy matplotlib lifelines fortranformat
    
  4. Activate the environment

    >> conda activate rpy2
    
  5. Now, install rpy2. Set to the latest version, e.g.,

    >> pip install rpy2==3.6.1
    
  6. Check the version of R. You can do this just by opening R and seeing what it prints:

    >> R
    R version 4.5.1 (2025-06-13) -- "Great Square Root"
     Copyright (C) 2025 The R Foundation for Statistical Computing
     Platform: aarch64-apple-darwin20
    
  1. open python and import rpy2. Make sure there are no errors
    import rpy2
    

About

Code collaboration for the Galaxy Group at Haverford College

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors