snapread: Read in Gadget snapshots

Description Usage Arguments Value Author(s) See Also Examples

View source: R/snapread.R

Description

This function allows the user to read in the standard format Gadget binaries. It keeps the particle information and header information in separate components of a list.

Usage

1

Arguments

file

The full path to the Gadget snapshot to be read in.

Value

part

A data.frame containing the main particle level information. Columns included are:

ID particle ID
x x position in units of Mpc
y y position in units of Mpc
z z position in units of Mpc
vx x velocity
vy y velocity
vz z velocity
Mass particle mass in units of Msun
head

A list containing various header information as list elements. These are:

Npart Vector of length 6 containing the number of particles in this snapshot file, where:
gas [1] / collisionless particles [2:6]
Massarr Vector of length 6 containing the particle masses for the respective particle types
in Npart
Time Time of snapshot in units of km/s and kpc so 1 unit is ~10 Gyrs
z Redshift of snapshot
FlagSfr Star formation turned on/off
Nall Vector of length 6 containing the number of particles in all snapshot files, where:
gas [1] / collisionless particles [2:6]
FlagFeedback Feedback turned on/off
FlagCooling Cooling turned on/off
NumFiles Number of files per snapshot- usually 1
BoxSize Size of simulation box edge length in units of kpc
OmegaM Omega matter of the simulation
OmegaL Omega lambda of the simulation
h Hubble constant divided by 100 used in the simulation
FlagAge Stellar ages on/off
FlagMetals Stellar metallacities on/off
NallHW Tell Gadget to use large integers for the respective particle types in Npart
- not usually necessary
flag_entr_ics Entropy for gas on/off

Author(s)

Aaron Robotham

See Also

snapwrite,addhead,genparam

Examples

1
2
3
4
## Not run: 
temp=snapread('somepath/snapshot_XXX')

## End(Not run)

snapshot documentation built on May 2, 2019, 1:08 p.m.