diff --git a/examples/galaxies/plot_demographics.py b/examples/galaxies/plot_demographics.py new file mode 100644 index 00000000..92501cca --- /dev/null +++ b/examples/galaxies/plot_demographics.py @@ -0,0 +1,239 @@ +""" +Galaxy Demographics +=================== + +In this example we reproduce the results from de la Bella et al. 2021 [1]_. +In that paper the authors distinguished between active galaxies +(centrals and satellites) and quiescent galaxies (mass-quenched and satellite-quenched), +describing the galaxy demographics with a set of continuity equations that are solved analytically. +Such equations invoke two quenching mechanisms that transform star-forming galaxies into quiescent +objects: mass quenching and satellite quenching. + +They showed that the combination of the two quenching mechanisms produces +a double Schechter function for the quiescent population. +They demonstrated that the satellite-quenched galaxies are indeed a subset +of the active galaxies and that the mass-quenched galaxies have a different +faint-end slope parameter by one unit. The connection between quenching and +galaxy populations reduced significantly the parameter space of the simulations. + +This example uses de la Bella et al. model implemented in `skypy.galaxies.stellar_mass` +and shows how to sample any type of galaxy population +from a general Schechter mass function. +""" + +# %% +# Schechter Parameters +# -------------------- +# +# We generate their Figure 4 and use the best-fit values of the blue parameters +# in Wiegel et al. 2016 [2]_. We follow de la Bella et al.'s procedure +# to compute the fraction of satellite galaxies from [2] +# and use their fixed value for the fraction of satellite-quenched galaxies +# :math:`f_{\rho} = 0.5`. +# +# Finally we generate the different galaxy samples by feeding the Schechter parameters +# as inputs for the Schechter mass function. + +import numpy as np +import matplotlib.pyplot as plt + +from astropy.cosmology import FlatLambdaCDM +from astropy.table import Table +from astropy.units import Quantity +from skypy.galaxies import schechter_smf +# from skypy.galaxies.stellar_mass import (schechter_smf_amplitude_centrals, + # schechter_smf_amplitude_satellites, + # schechter_smf_amplitude_mass_quenched, + # schechter_smf_amplitude_satellite_quenched +# ) + +# %% + + +# Weigel et al. 2016 parameters for the active population +phiblue = 10**-2.423 +mstarb = 10**10.60 +alphab = -1.21 +blue = (phiblue, alphab, mstarb) + +# Fraction of satellite-quenched galaxies and satellites +frho = 0.5 +fsat = 0.4 + +# Weigel+16 redshift and cosmology +z_min, z_max = 0.02, 0.06 +z_range = np.linspace(z_min, z_max, 100) +cosmology = FlatLambdaCDM(H0=70, Om0=0.3) + +# Sky area (SDSS DR7 8423 deg2) +sky_area = Quantity(2000, "deg2") + +# %% +# First we use the model implemented in `skypy.galaxies.stellar_mass`. + + +# To be replaced by the SkyPy function once it's merged +def schechter_smf_phi_centrals(phi_blue_total, fsatellite): + if np.ndim(phi_blue_total) == 1 and np.ndim(fsatellite) == 1: + phi_blue_total = phi_blue_total[:, np.newaxis] + + sum_phics = (1 - fsatellite) * (1 - np.log(1 - fsatellite)) + return (1 - fsatellite) * phi_blue_total / sum_phics + + +def schechter_smf_phi_satellites(phi_centrals, fsatellite): + return phi_centrals * np.log(1 / (1 - fsatellite)) + + +def schechter_smf_phi_mass_quenched(phi_centrals, phi_satellites): + return phi_centrals + phi_satellites + + +def schechter_smf_phi_satellite_quenched(phi_satellites, fenvironment): + return - np.log(1 - fenvironment) * phi_satellites + + +# SkyPy amplitudes +phic = schechter_smf_phi_centrals(phiblue, fsat) +phis = schechter_smf_phi_satellites(phic, fsat) +phimq = schechter_smf_phi_mass_quenched(phic, phis) +phisq = schechter_smf_phi_satellite_quenched(phis, frho) + + +# %% +# Finally we simulate the galaxy populations. + + +# Schechter mass functions +z_centrals, m_centrals = schechter_smf(z_range, mstarb, phic, alphab, 1e9, 1e12, sky_area, cosmology) +z_satellites, m_satellites = schechter_smf(z_range, mstarb, phis, alphab, 1e9, 1e12, sky_area, cosmology) +z_massq, m_mass_quenched = schechter_smf(z_range, mstarb, phimq, alphab + 1, 1e9, 1e12, sky_area, cosmology) +z_satq, m_satellite_quenched = schechter_smf(z_range, mstarb, phisq, alphab, 1e9, 1e12, sky_area, cosmology) + + +logm_centrals = np.log10(m_centrals) +logm_satellites = np.log10(m_satellites) +logm_massq = np.log10(m_mass_quenched) +logm_satq = np.log10(m_satellite_quenched) + +# log Mass bins +bins = np.linspace(9, 12, 35) + +# Sky volume +dV_dz = (cosmology.differential_comoving_volume(z_range) * sky_area).to_value('Mpc3') +dV = np.trapz(dV_dz, z_range) +dlm = (np.max(bins)-np.min(bins)) / (np.size(bins)-1) + +# log distribution of masses +logphi_centrals = np.histogram(logm_centrals, bins=bins)[0] / dV / dlm +logphi_satellites = np.histogram(logm_satellites, bins=bins)[0] / dV / dlm +logphi_massq = np.histogram(logm_massq, bins=bins)[0] / dV / dlm +logphi_satq = np.histogram(logm_satq, bins=bins)[0] / dV / dlm + +logphi_active = logphi_centrals + logphi_satellites +logphi_passive = logphi_massq + logphi_satq +logphi_total = logphi_active + logphi_passive + + +# %% +# Validation against SSD DR7 data +# ------------------------------- +# +# Here we compare our sampled galaxies and +# we validate the model using the results from the best fit to +# SDSS DR7 data in Weigel et al. (2016) [2]. +# The authors presented a comprehensive method to determine +# stellar mass functions and apply it to samples in the local universe, +# in particular to SDSS DR7 data in the redshift range from 0.02 to 0.06. +# +# Their data is presented as logarithmic distribution, therefore, +# to perform the comparison we need to apply a conversion factor. +# This factor allows us to go from :math:`\phi` to a :math:`\log \phi` plot +# and compare with Weigel et al 2016 best-fit model. + + +# Load the data +wtotal = Table.read('weigel16_total.csv', format='csv') +wred = Table.read('weigel16_quiescent.csv', format='csv') +wblue = Table.read('weigel16_active.csv', format='csv') +wcentral = Table.read('weigel16_central.csv', format='csv') +wsatellite = Table.read('weigel16_satellite.csv', format='csv') + +# %% + + +# Plot +fig, (ax1, ax2, ax3) = plt.subplots(nrows=1, ncols=3, figsize=(16, 6), sharex=True, sharey=True) +fig.suptitle('Galaxy Demographics Simulation', fontsize=26) + +ax1.plot(wblue['logm'], 10**wblue['logphi'], color='k', label='Weigel+16 active', lw=1) +ax1.step(bins[:-1], logphi_active, where='post', label='SkyPy active', color='blue', zorder=3, lw=1) +ax1.step(bins[:-1], logphi_centrals, where='post', label='SkyPy centrals', color='royalblue', zorder=3, lw=1) +ax1.step(bins[:-1], logphi_satellites, where='post', label='SkyPy satellites', color='cyan', zorder=3, lw=1) + + +ax2.plot(wred['logm'], 10**wred['logphi'], color='k', label='Weigel+16 passive', lw=1) +ax2.fill_between(wred['logm'], 10**wred['upper_error'], 10**wred['lower_error'], color='salmon', alpha=0.1) +ax2.step(bins[:-1], logphi_passive, where='post', label='SkyPy passive', color='red', zorder=3, lw=1) +ax2.step(bins[:-1], logphi_massq, where='post', label='SkyPy mass-quenched', color='coral', zorder=3, lw=1) +ax2.step(bins[:-1], logphi_satq, where='post', label='SkyPy sat-quenched', color='maroon', zorder=3, lw=1) + +ax3.plot(wtotal['logm'], 10**wtotal['logphi'], color='k', label='Weigel+16 total', lw=1) +ax3.plot(wcentral['logm'], 10**wcentral['logphi'], '--', color='grey', label='Weigel+16 centrals', lw=1) +ax3.plot(wsatellite['logm'], 10**wsatellite['logphi'], '--', color='grey', label='Weigel+16 satellites', lw=1) +ax3.fill_between(wtotal['logm'], 10**wtotal['upper_error'], 10**wtotal['lower_error'], color='plum', alpha=0.1) +ax3.step(bins[:-1], logphi_total, where='post', label='SkyPy total', color='purple', zorder=3, lw=1) + +for ax in [ax1, ax2, ax3]: + ax.legend(loc='lower left', fontsize='small', frameon=False) + ax.set_xlabel(r'Stellar mass, $log (M/M_{\odot})$', fontsize=18) + ax.set_xlim((9, 11.9)) + ax.set_ylim((2e-6,5e-2)) + ax.set_yscale('log') + + +ax1.set_ylabel(r'$\phi /h^3 Mpc^{-3}$', fontsize=18) +# plt.savefig('galaxy_simulation.pdf') +plt.tight_layout() +plt.show() + + +# %% +# Sonification +# ------------ +# The sonification, or transformation of physical data via sound, +# is becoming increasingly important to make astronomy accessible +# for those who are visually impaired, and to enhance visualisations +# and convey information that visualisation alone cannot. +# In this work [1] the authors also made their main plot available +# in sound format using the `STRAUSS`_ software (Trayford 2021) [3]_. + +import IPython +# Active population +IPython.display.Audio("skypy_sim_active.wav") + +# %% + +# Mass-quenched galaxies +IPython.display.Audio("skypy_sim_massq.wav") + +# %% + +# Satellite-quenched galaxies +IPython.display.Audio("skypy_sim_satq.wav") + + +# %% +# References +# ---------- +# +# .. [1] de la Bella et al. 2021, Quenching and Galaxy Demographics, arXiv 2112.11110. +# +# .. [2] Weigel A. K., Schawinski K., Bruderer C., 2016, Monthly Notices of the +# Royal Astronomical Society, 459, 2150 +# +# .. [3] Trayford J., 2021, james-trayford/strauss: v0.1.0 Pre-release, `doi:10.5281/zenodo.5776280`_. +# +# .. _doi:10.5281/zenodo.5776280: https://doi.org/10.5281/zenodo.5776280 +# +# .. _STRAUSS: https://strauss.readthedocs.io/en/latest/ diff --git a/examples/galaxies/skypy_passive.wav b/examples/galaxies/skypy_passive.wav new file mode 100644 index 00000000..17020f4a Binary files /dev/null and b/examples/galaxies/skypy_passive.wav differ diff --git a/examples/galaxies/skypy_sim_active.wav b/examples/galaxies/skypy_sim_active.wav new file mode 100644 index 00000000..4589b07f Binary files /dev/null and b/examples/galaxies/skypy_sim_active.wav differ diff --git a/examples/galaxies/skypy_sim_massq.wav b/examples/galaxies/skypy_sim_massq.wav new file mode 100644 index 00000000..88640291 Binary files /dev/null and b/examples/galaxies/skypy_sim_massq.wav differ diff --git a/examples/galaxies/skypy_sim_satq.wav b/examples/galaxies/skypy_sim_satq.wav new file mode 100644 index 00000000..e9b4a013 Binary files /dev/null and b/examples/galaxies/skypy_sim_satq.wav differ diff --git a/examples/galaxies/weigel16_active.csv b/examples/galaxies/weigel16_active.csv new file mode 100644 index 00000000..2b61da2c --- /dev/null +++ b/examples/galaxies/weigel16_active.csv @@ -0,0 +1,52 @@ +logm,logphi,upper_error,lower_error +9.013996889580094,-1.751662778641784,-1.7369399084154145,-1.757217038189045 +9.065318818040435,-1.7608151892172117,-1.7476177207534134,-1.7694202522896152 +9.139968895800934,-1.774127786417834,-1.7631490841541393,-1.787170381890445 +9.186625194401245,-1.7834562254139612,-1.773456225413961,-1.798456225413961 +9.237947122861586,-1.7963772756380938,-1.7863772756380938,-1.811377275638094 +9.349922239502332,-1.8288046334531025,-1.8188046334531025,-1.8438046334531026 +9.415241057542769,-1.8474828761457271,-1.8374828761457271,-1.863106449157871 +9.573872472783826,-1.8908196287349863,-1.8808196287349863,-1.9100545977962353 +9.629860031104199,-1.9081781284375836,-1.8981781284375836,-1.9281781284375838 +9.755832037325039,-1.9542039980275392,-1.9442039980275392,-1.9742039980275394 +9.8398133748056,-1.9858546585607249,-1.9758546585607246,-2.005854658560725 +9.979782270606531,-2.04031528347236,-2.03031528347236,-2.0603152834723604 +10.049766718506998,-2.07347316212013,-2.06347316212013,-2.094777226682359 +10.175738724727838,-2.1390466983313026,-2.1290466983313023,-2.1639937371274858 +10.250388802488336,-2.1904162473698667,-2.1758329521544244,-2.2108329521544245 +10.381026438569208,-2.283465526179369,-2.272888802488337,-2.303465526179369 +10.455676516329705,-2.3539982226171974,-2.343998222617197,-2.3739982226171974 +10.565318818040435,-2.4661782761725473,-2.456178276172547,-2.485920847998691 +10.614307931570762,-2.532390930670378,-2.522390930670378,-2.5493746418924457 +10.656298600311043,-2.5898083579992996,-2.5798083579992994,-2.60550895499925 +10.758942457231726,-2.7386088396127017,-2.728608839612702,-2.7649380424421808 +10.79860031104199,-2.79840435458787,-2.78840435458787,-2.8281041990668747 +10.847589424572316,-2.8962519440124406,-2.8862519440124403,-2.9224572317262822 +10.964230171073094,-3.164797822706063,-3.1547978227060627,-3.1897978227060633 +11.001555209953343,-3.2599934202655803,-3.24999342026558,-3.291659289388681 +11.043545878693624,-3.375161815892767,-3.3651618158927668,-3.419934088721028 +11.06687402799378,-3.455988298896544,-3.445988298896544,-3.497194697474638 +11.150855365474339,-3.75214858236631,-3.74214858236631,-3.783026677832275 +11.188180404354588,-3.899611197511665,-3.889611197511665,-3.9335614307931586 +11.220839813374806,-4.039066874027994,-4.029066874027994,-4.079875583203733 +11.253499222395023,-4.185854908059646,-4.175854908059646,-4.236147653462629 +11.276827371695179,-4.303319001006313,-4.293319001006314,-4.359484951056629 +11.332814930015552,-4.586227060653192,-4.576227060653192,-4.656449455676522 +11.356143079315707,-4.726009331259725,-4.716009331259724,-4.801223950233287 +11.384136858475895,-4.899372731985495,-4.889372731985494,-4.980578019699337 +11.40746500777605,-5.062452047693113,-5.052452047693113,-5.148649559357189 +11.426127527216174,-5.192915500259203,-5.1829155002592024,-5.283106791083465 +11.444790046656298,-5.323378952825292,-5.313378952825293,-5.417564022809741 +11.468118195956453,-5.492027993779154,-5.4820279937791545,-5.584939346811814 +11.519440124416796,-5.91852255054433,-5.883182348367036,-5.995 +11.542768273716952,-6.0,-5.995,-5.995 +11.5800933125972,-6.0,-5.995,-5.995 +11.608087091757387,-6.0,-5.995,-5.995 +11.636080870917574,-6.0,-5.995,-5.995 +11.673405909797822,-6.0,-5.995,-5.995 +11.706065318818041,-6.0,-5.995,-5.995 +11.724727838258165,-6.0,-5.995,-5.995 +11.74805598755832,-6.0,-5.995,-5.995 +11.766718506998444,-6.0,-5.995,-5.995 +11.780715396578538,-6.0,-5.995,-5.995 +11.808709175738725,-6.0,-5.995,-5.995 diff --git a/examples/galaxies/weigel16_central.csv b/examples/galaxies/weigel16_central.csv new file mode 100644 index 00000000..91d9a220 --- /dev/null +++ b/examples/galaxies/weigel16_central.csv @@ -0,0 +1,52 @@ +logm,logphi,upper_error,lower_error +9.013996889580094,-1.901453957996769,-1.8045234248788353,-2.017770597738289 +9.065318818040435,-1.9084282085920479,-1.809745866849437,-2.017770597738289 +9.139968895800934,-1.9185761939804045,-1.8173566438795332,-2.017770597738289 +9.186625194401245,-1.9233041223271303,-1.8215202111860989,-2.0202411805566842 +9.237947122861586,-1.9275190501441357,-1.8257351390031042,-2.02445610837369 +9.349922239502332,-1.9367152562903298,-1.8349313451492981,-2.033652314519884 +9.415241057542769,-1.941285305619963,-1.8400319710462265,-2.0387510293810056 +9.573872472783826,-1.948729638681243,-1.8511986854074345,-2.0499177437422134 +9.629860031104199,-1.9528651328326536,-1.8551923497949228,-2.0531731908719033 +9.755832037325039,-1.9649773484286204,-1.8642763325112712,-2.0592290600337533 +9.8398133748056,-1.9711786711822379,-1.870332320988837,-2.0651434225686924 +9.979782270606531,-1.9779074146954043,-1.880425635118113,-2.078601439897544 +10.049766718506998,-1.9834370977518496,-1.8864991072917772,-2.0863337305089877 +10.175738724727838,-1.9952609050752397,-1.8983229146151672,-2.1011137739385646 +10.250388802488336,-2.006340782508102,-1.9093949697002188,-2.1119844017507146 +10.381026438569208,-2.0314643948854285,-1.934518582077545,-2.133967129423679 +10.455676516329705,-2.0516150864132165,-1.9525967494469734,-2.154453865139024 +10.565318818040435,-2.086802807443267,-1.982756519787154,-2.1921557032289236 +10.614307931570762,-2.1025249806694597,-1.9962321618540433,-2.2090012053541983 +10.656298600311043,-2.1246172383428195,-2.0179436199903673,-2.232383575046536 +10.758942457231726,-2.1833779030450664,-2.0767042846926143,-2.2944103380857555 +10.79860031104199,-2.212105873279827,-2.1054104671098126,-2.3236510706393863 +10.847589424572316,-2.2551202677917614,-2.14798633627989,-2.3658294825168618 +10.964230171073094,-2.3736469254314545,-2.2630240975821945,-2.4773785184139365 +11.001555209953343,-2.4140830538368827,-2.3024818187243987,-2.5165248918779795 +11.043545878693624,-2.4743431518967496,-2.3627419167842634,-2.5805559535406077 +11.06687402799378,-2.5114401646702804,-2.399819781817757,-2.618207487398778 +11.150855365474339,-2.649559916255992,-2.537939533403471,-2.756327238984492 +11.188180404354588,-2.717767141282523,-2.611211984586968,-2.824563257787379 +11.220839813374806,-2.791526329880765,-2.6864514919945846,-2.8952644416348776 +11.253499222395023,-2.8778767355095543,-2.7662768054628986,-2.975289651715326 +11.276827371695179,-2.942391759804674,-2.8319465420265875,-3.0421141940389838 +11.332814930015552,-3.0972278181129607,-2.98955390977944,-3.202493095615763 +11.356143079315707,-3.1643132107623333,-3.056839098475677,-3.2723935117850034 +11.384136858475895,-3.2518953137361692,-3.142110654673184,-3.3645976440080827 +11.40746500777605,-3.324880399547697,-3.213170284837771,-3.4414344208606473 +11.426127527216174,-3.4048657327766576,-3.2930013259969915,-3.5166434276997007 +11.444790046656298,-3.4854019994246777,-3.3735375926450115,-3.5921294895329563 +11.468118195956453,-3.5887935091801797,-3.4764797088355044,-3.691388145746976 +11.519440124416796,-3.832501920681778,-3.7167902901228724,-3.9384947548553852 +11.542768273716952,-3.9467760360038087,-3.8273056526447142,-4.053855682021509 +11.5800933125972,-4.141548879010175,-4.008592408869329,-4.248628525027869 +11.608087091757387,-4.3088210558961455,-4.170542654256135,-4.415998710978959 +11.636080870917574,-4.486293796788272,-4.34522819994518,-4.593471451871093 +11.673405909797822,-4.729953212353477,-4.606175961222472,-4.868885879439324 +11.706065318818041,-4.9637477231195515,-4.8341168340423035,-5.114926265519992 +11.724727838258165,-5.116771085496064,-4.970450378772958,-5.259629025528218 +11.74805598755832,-5.323471384715013,-5.15366956352008,-5.446522555966339 +11.766718506998444,-5.476882150930529,-5.315071620084174,-5.607924612530431 +11.780715396578538,-5.593426578386139,-5.436334462516161,-5.728603848101238 +11.808709175738725,-5.8786676506827655,-5.707588220947513,-5.976751605056448 diff --git a/examples/galaxies/weigel16_quiescent.csv b/examples/galaxies/weigel16_quiescent.csv new file mode 100644 index 00000000..ea344baf --- /dev/null +++ b/examples/galaxies/weigel16_quiescent.csv @@ -0,0 +1,52 @@ +logm,logphi,upper_error,lower_error +9.013996889580094,-2.4099074909413374,-1.9363995571180705,-2.8877997780991898 +9.065318818040435,-2.451906868490668,-1.9828528266441285,-2.926004463988489 +9.139968895800934,-2.507662090045572,-2.047074490780902,-2.9708344336589163 +9.186625194401245,-2.5351960593664247,-2.067726455202708,-2.99266592134282 +9.237947122861586,-2.5452010808022125,-2.0682983264859196,-2.9991459628150854 +9.349922239502332,-2.555346294911005,-2.06954604564929,-3.00725265116265 +9.415241057542769,-2.5392829695351886,-2.0702738818279225,-2.9980426789818977 +9.573872472783826,-2.49244244584182,-2.0470412110374636,-2.9532529679222512 +9.629860031104199,-2.477310378553239,-2.0292756450051836,-2.9336811893543873 +9.755832037325039,-2.4281787705415168,-1.9797993566448613,-2.8869393426280747 +9.8398133748056,-2.3938954506090306,-1.9459661064765439,-2.854854932769421 +9.979782270606531,-2.336500797568966,-1.8911599876923058,-2.8016283852229655 +10.049766718506998,-2.314423038992038,-1.8637569283001862,-2.7764902933046947 +10.175738724727838,-2.2795294575829317,-1.8261298937567578,-2.7341234734314104 +10.250388802488336,-2.259359397460064,-1.804631052715899,-2.7165532020611334 +10.381026438569208,-2.224061792245046,-1.7780633792345126,-2.689726079211546 +10.455676516329705,-2.221391568259061,-1.7636513697562728,-2.685291582591203 +10.565318818040435,-2.221076669691986,-1.7688199919980168,-2.685640453245028 +10.614307931570762,-2.2267336714140384,-1.775473845420117,-2.692024132031607 +10.656298600311043,-2.233712585044603,-1.7843090467929923,-2.6974958567058174 +10.758942457231726,-2.2662721865295,-1.8174709693741236,-2.730072341057386 +10.79860031104199,-2.28643847593858,-1.839933623479938,-2.7476895572558457 +10.847589424572316,-2.3222525758384736,-1.8676816079635894,-2.774662419537336 +10.964230171073094,-2.411450439808251,-1.9657467029229967,-2.87122055475078 +11.001555209953343,-2.45119469417148,-1.998456234779214,-2.9112970043435062 +11.043545878693624,-2.500349905316557,-2.050567992229555,-2.9649785616985778 +11.06687402799378,-2.5329489829161713,-2.082882543870272,-2.994801649118061 +11.150855365474339,-2.6761891824120654,-2.222657187393506,-3.1317049444895546 +11.188180404354588,-2.7398514932991334,-2.292697646686928,-3.197447086378694 +11.220839813374806,-2.8118909336618962,-2.3573030878205516,-3.2773463539558954 +11.253499222395023,-2.8920758606385286,-2.4379747039374062,-3.3609552752598884 +11.276827371695179,-2.955349369037258,-2.495597286878017,-3.4206759333341696 +11.332814930015552,-3.112263200871992,-2.6575430492837073,-3.5783321147475213 +11.356143079315707,-3.1807039837205884,-2.732212492685386,-3.6474865520308795 +11.384136858475895,-3.269723952463168,-2.8241955641356653,-3.7393896972401883 +11.40746500777605,-3.3533747439858677,-2.9175509891965947,-3.8159756515812773 +11.426127527216174,-3.4280590840346066,-2.9922353292453354,-3.9020570204427143 +11.444790046656298,-3.5088566356216924,-3.066919669294076,-3.9889721848502337 +11.468118195956453,-3.6173797735195303,-3.1584299414801955,-4.088365172062533 +11.519440124416796,-3.8599557102419837,-3.389694345131582,-4.320397415689584 +11.542768273716952,-3.985133725174385,-3.523775627654973,-4.449048583884645 +11.5800933125972,-4.192304375204472,-3.7302729492378246,-4.661529964985638 +11.608087091757387,-4.36532363425187,-3.8796714226294395,-4.8224275040137154 +11.636080870917574,-4.550363163332442,-4.065172747768958,-5.016553733158989 +11.673405909797822,-4.789424555394305,-4.312790504936385,-5.278945136601894 +11.706065318818041,-5.060409462111512,-4.556880446422363,-5.531724478527623 +11.724727838258165,-5.219803585682173,-4.72125749843549,-5.689152244686008 +11.74805598755832,-5.425636942424524,-4.915835847185201,-5.897094541033947 +11.766718506998444,-5.5907258413580045,-5.070800701029227,-5.991180294257456 +11.780715396578538,-5.714542515558122,-5.207288274057083,-5.991180294257456 +11.808709175738725,-5.991022799512053,-5.498575714651385,-5.991180294257456 diff --git a/examples/galaxies/weigel16_satellite.csv b/examples/galaxies/weigel16_satellite.csv new file mode 100644 index 00000000..71d88740 --- /dev/null +++ b/examples/galaxies/weigel16_satellite.csv @@ -0,0 +1,52 @@ +logm,logphi,upper_error,lower_error +9.013996889580094,-1.9303797468354427,-1.6123417721518978,-2.2484177215189947 +9.065318818040435,-1.9490118932782863,-1.6333029369000962,-2.2658853588091605 +9.139968895800934,-1.9827056715947788,-1.6712084375061496,-2.2974732759808725 +9.186625194401245,-2.0037642830425866,-1.6948993753849326,-2.317215724213192 +9.237947122861586,-2.022715192557899,-1.7151950186750433,-2.333958071969182 +9.349922239502332,-2.0629179962309863,-1.7579104975776974,-2.3691355251831334 +9.415241057542769,-2.085418201312932,-1.781620732958497,-2.389738956384082 +9.573872472783826,-2.129127063445882,-1.8253295950914457,-2.4407326288725235 +9.629860031104199,-2.143884169268686,-1.8396223346202925,-2.455782209627328 +9.755832037325039,-2.1742201263085916,-1.8669246959562071,-2.4770173795552624 +9.8398133748056,-2.1930517550249027,-1.8845074512274274,-2.4936881115026552 +9.979782270606531,-2.22069118255015,-1.912146878752674,-2.528237395909214 +10.049766718506998,-2.2340429271694893,-1.9266685462302249,-2.543757153825177 +10.175738724727838,-2.257733865048273,-1.9533208513438567,-2.5704094589388085 +10.250388802488336,-2.2786089729708445,-1.9748115046164068,-2.5919001122113587 +10.381026438569208,-2.3216036380101186,-2.0178061696556804,-2.6348947772506324 +10.455676516329705,-2.3553571455612907,-2.051559677206853,-2.668648284801805 +10.565318818040435,-2.410872235035078,-2.10707476668064,-2.724163374275592 +10.614307931570762,-2.443142104330652,-2.1393446359762143,-2.7558366350893144 +10.656298600311043,-2.4780550654151767,-2.174257597060739,-2.7896585661399476 +10.758942457231726,-2.5633978591773436,-2.259600390822906,-2.8723343975970463 +10.79860031104199,-2.605050495107978,-2.299636297419131,-2.9152115282398636 +10.847589424572316,-2.663492266603668,-2.3549479628061922,-2.9767309093056715 +10.964230171073094,-2.8341060167595167,-2.5255617129620407,-3.1430793157076153 +11.001555209953343,-2.8988323187219223,-2.590288014924447,-3.2073766225193863 +11.043545878693624,-2.976873055263801,-2.6683287514663263,-3.2854173590612623 +11.06687402799378,-3.024749071233116,-2.716204767435643,-3.3332933750305767 +11.150855365474339,-3.22217355355631,-2.913629249758847,-3.5307178573537707 +11.188180404354588,-3.316303620292535,-3.010674596925021,-3.630678484949889 +11.220839813374806,-3.412047418691509,-3.105717141491897,-3.73135179779764 +11.253499222395023,-3.5234426872023556,-3.2112495011337514,-3.8456785207429824 +11.276827371695179,-3.6104913986839224,-3.294516978313063,-3.9323817817670426 +11.332814930015552,-3.825787992038478,-3.5010853313964887,-4.144768961697888 +11.356143079315707,-3.9160334271708876,-3.5900365671201047,-4.235094592200309 +11.384136858475895,-4.026591137271881,-3.7088861054786717,-4.351180187806352 +11.40746500777605,-4.129122413725215,-3.815831274484716,-4.457694044431744 +11.426127527216174,-4.225860410063583,-3.912569270823084,-4.556735326397216 +11.444790046656298,-4.324397848298123,-4.011106709057624,-4.657126189784815 +11.468118195956453,-4.451078557788839,-4.137787418548339,-4.785246452792472 +11.519440124416796,-4.737206429513544,-4.422057712561764,-5.0754701311100865 +11.542768273716952,-4.898436423410822,-4.574650385357403,-5.242458339075125 +11.5800933125972,-5.149688342815504,-4.8322308034923225,-5.492849294741791 +11.608087091757387,-5.361638341971818,-5.036540754656491,-5.701049204255577 +11.636080870917574,-5.598465460558693,-5.258704992420821,-5.935490777014381 +11.673405909797822,-5.930138590861643,-5.577483045258566,-6.263481972360543 +11.706065318818041,-6.227168927298847,-5.855098070096004,-6.552225853232785 +11.724727838258165,-6.423715967478382,-6.043455650268059,-6.759009718421671 +11.74805598755832,-6.639240506329115,-6.25000000000001,-6.985759493670878 +11.766718506998444,-6.639240506329115,-6.25000000000001,-6.985759493670878 +11.780715396578538,-6.639240506329115,-6.25000000000001,-6.985759493670878 +11.808709175738725,-6.639240506329115,-6.25000000000001,-6.985759493670878 diff --git a/examples/galaxies/weigel16_total.csv b/examples/galaxies/weigel16_total.csv new file mode 100644 index 00000000..2f5dfb30 --- /dev/null +++ b/examples/galaxies/weigel16_total.csv @@ -0,0 +1,52 @@ +logm,logphi,upper_error,lower_error +9.013996889580094,-1.5619047619047612,-1.3948717948717941,-1.7278911564625843 +9.065318818040435,-1.5809523809523802,-1.4116402116402105,-1.7503401360544208 +9.139968895800934,-1.609523809523809,-1.4455026455026452,-1.776190476190476 +9.186625194401245,-1.6190476190476186,-1.4608058608058603,-1.7926190476190476 +9.237947122861586,-1.6380952380952374,-1.4769230769230761,-1.8109523809523804 +9.349922239502332,-1.6714285714285713,-1.5090909090909084,-1.8426303854875279 +9.415241057542769,-1.6904761904761898,-1.5322344322344317,-1.8585034013605437 +9.573872472783826,-1.7190476190476187,-1.5676190476190472,-1.8960317460317455 +9.629860031104199,-1.7333333333333325,-1.5783549783549777,-1.9067669172932324 +9.755832037325039,-1.7571428571428567,-1.5980952380952373,-1.9267399267399261 +9.8398133748056,-1.7714285714285707,-1.6075187969924807,-1.9392446633825942 +9.979782270606531,-1.7809523809523804,-1.6210526315789464,-1.9589490968801309 +10.049766718506998,-1.7904761904761899,-1.628571428571428,-1.968801313628899 +10.175738724727838,-1.8142857142857136,-1.6499999999999992,-1.9882783882783877 +10.250388802488336,-1.8285714285714278,-1.6654761904761899,-2.0032840722495893 +10.381026438569208,-1.8571428571428563,-1.6949404761904756,-2.032234432234432 +10.455676516329705,-1.8857142857142848,-1.7186813186813181,-2.050931677018633 +10.565318818040435,-1.9238095238095236,-1.760884353741496,-2.0920168067226883 +10.614307931570762,-1.9428571428571422,-1.7845804988662128,-2.1184873949579823 +10.656298600311043,-1.9619047619047612,-1.8049886621315196,-2.1413919413919413 +10.758942457231726,-2.0380952380952375,-1.8761904761904749,-2.2107936507936494 +10.79860031104199,-2.066666666666666,-1.9031746031746024,-2.2448979591836724 +10.847589424572316,-2.1142857142857134,-1.9489795918367332,-2.287755102040814 +10.964230171073094,-2.2380952380952377,-2.078095238095237,-2.415873015873015 +11.001555209953343,-2.285714285714285,-2.1238095238095234,-2.4666666666666663 +11.043545878693624,-2.352380952380952,-2.19047619047619,-2.534523809523811 +11.06687402799378,-2.3999999999999995,-2.2307692307692313,-2.573992673992676 +11.150855365474339,-2.5619047619047612,-2.3841269841269837,-2.7333333333333316 +11.188180404354588,-2.628571428571428,-2.461904761904761,-2.809523809523809 +11.220839813374806,-2.714285714285714,-2.5460317460317454,-2.8928571428571406 +11.253499222395023,-2.79047619047619,-2.63265306122449,-2.971428571428571 +11.276827371695179,-2.8571428571428568,-2.694505494505494,-3.03265306122449 +11.332814930015552,-3.028571428571429,-2.8670194003527323,-3.2108843537414944 +11.356143079315707,-3.1047619047619044,-2.9428571428571426,-3.2931972789115664 +11.384136858475895,-3.1999999999999997,-3.0357142857142865,-3.3952380952380956 +11.40746500777605,-3.285714285714285,-3.1238095238095256,-3.480952380952381 +11.426127527216174,-3.3619047619047615,-3.1999999999999997,-3.547619047619048 +11.444790046656298,-3.457142857142857,-3.270748299319726,-3.6228571428571414 +11.468118195956453,-3.5523809523809518,-3.3657142857142843,-3.728042328042327 +11.519440124416796,-3.8,-3.6219780219780224,-3.9933333333333345 +11.542768273716952,-3.923809523809523,-3.7428571428571424,-4.11746031746032 +11.5800933125972,-4.123809523809523,-3.9428571428571333,-4.325714285714281 +11.608087091757387,-4.314285714285714,-4.1028571428571405,-4.508225108225106 +11.636080870917574,-4.514285714285714,-4.302857142857146,-4.704761904761913 +11.673405909797822,-4.771428571428571,-4.561904761904758,-4.97354497354497 +11.706065318818041,-5.0,-4.784126984126994,-5.201904761904765 +11.724727838258165,-5.190476190476191,-4.955555555555552,-5.369523809523807 +11.74805598755832,-5.3809523809523805,-5.152380952380949,-5.552380952380952 +11.766718506998444,-5.533333333333333,-5.3150183150183095,-5.747089947089943 +11.780715396578538,-5.6571428571428575,-5.438095238095238,-5.876190476190477 +11.808709175738725,-5.942857142857143,-5.6911564625850435,-5.980952380952381 diff --git a/setup.cfg b/setup.cfg index baeb275f..9b6b7528 100644 --- a/setup.cfg +++ b/setup.cfg @@ -39,6 +39,7 @@ docs = sphinx-astropy matplotlib speclite>=0.14 + ipython [options.package_data] skypy = data/*,data/*/*,*/tests/data/*