## MAGPHYS+photo -z : Constraining the Physical Properties of Galaxies with Unknown Redshifts

A. J. Battisti, 1, 2 E. da Cunha, 1,3,2 K. Grasha, 1,2 M. Salvato, 4 E. Daddi, 5 L. Davies, 6 S. Jin, 5, 7, 8 D. Liu, 9 E. Schinnerer, 9 and M. Vaccari 10,11

(COSMOS collaboration)

- 1 Research School of Astronomy and Astrophysics, Australian National University, Cotter Road, Weston Creek, ACT 2611, Australia 2 ARC Centre of Excellence for All Sky Astrophysics in 3 Dimensions (ASTRO 3D), Australia 3 International Centre for Radio Astronomy Research, University of Western Australia, 35 Stirling Hwy, Crawley, WA 6009, Australia 4 Max-Planck-Institut f¨r extraterrestrische Physik, Giessenbachstrasse 1, D-85748, Garching, Bayern, Germany u 5 CEA, IRFU, DAp, AIM, Universit´ e Paris-Saclay, Universit´ Paris Diderot, Sorbonne Paris Cit´, CNRS, F-91191 Gif-sur-Yvette, e e France 6 ICRAR, The University of Western Australia, 35 Stirling Highway, Crawley, WA 6009, Australia 7 School of Astronomy and Space Science, Nanjing University, Nanjing 210093, Peoples Republic of China 8 Key Laboratory of Modern Astronomy and Astrophysics, Nanjing University, Nanjing 210093, Peoples Republic of China 9 Max-Planck-Institut f¨r Astronomie, K¨nigstuhl 17, D-69117 Heidelberg, Germany u o 10 Department of Physics and Astronomy, University of the Western Cape, Robert Sobukwe Road, 7535 Bellville, Cape Town, South Africa 11 INAF - Istituto di Radioastronomia, via Gobetti 101, 40129 Bologna, Italy

## ABSTRACT

We present an enhanced version of the multiwavelength spectral modeling code MAGPHYS that allows the estimation of galaxy photometric redshift and physical properties (e.g., stellar mass, star formation rate, dust attenuation) simultaneously, together with robust characterization of their uncertainties. The self-consistent modeling over ultraviolet to radio wavelengths in MAGPHYS+photo -z is unique compared to standard photometric redshift codes. The broader wavelength consideration is particularly useful for breaking certain degeneracies in color vs. redshift for dusty galaxies with limited observer-frame ultraviolet and optical data (or upper limits). We demonstrate the success of the code in estimating redshifts and physical properties for over 4,000 infrared-detected galaxies at 0 4 . &lt; z &lt; 6 0 in the COSMOS field with robust spectroscopic redshifts. We achieve high photo-. z precision ( σ ∆ z/ (1+ z spec ) /lessorsimilar 0 04), high accuracy (i.e., minimal offset biases; median(∆ . z/ (1 + z spec )) /lessorsimilar 0 02), . and low catastrophic failure rates ( η /similarequal 4%) over all redshifts. Interestingly, we find that a weak 2175 ˚ A absorption feature in the attenuation curve models is required to remove a subtle systematic z phot offset ( z phot -z spec /similarequal -0 03) that occurs when this feature is not included. . As expected, the accuracy of derived physical properties in MAGPHYS+photo -z decreases strongly as redshift uncertainty increases. The all-in-one treatment of uncertainties afforded with this code is beneficial for accurately interpreting physical properties of galaxies in large photometric datasets. Finally, we emphasize that MAGPHYS+photo -z is not intended to replace existing photoz codes, but rather offer flexibility to robustly interpret physical properties when spectroscopic redshifts are unavailable. The MAGPHYS+photo -z code is publicly available online.

## 1. INTRODUCTION

Obtaining accurate distances to galaxies, typically inferred from cosmological redshift ( z ; Hogg 1999; Condon &amp; Matthews 2018), is an essential first step in any observational study of cosmology or galaxy evolution. This is because the distance is required

Corresponding author: A. J. Battisti

andrew.battisti@anu.edu.au

to derive meaningful physical properties for a galaxy from the observed spectral energy distribution (SED; see Walcher et al. 2011; Conroy 2013, for reviews of SED-fitting). However, due to the observational expense required to obtain accurate redshifts via spectroscopy, z spec , it is much more practical to estimate redshifts using photometric observations, z phot . This has spawned numerous 'photoz ' codes designed to accurately estimate redshifts from photometric data (see recent review by Salvato et al. 2018). A majority of these codes employ libraries of spec-

tral models of stellar populations or galaxies (either empiricallyor theoretically-based) that are combined in a linear, positive-only combination to determine redshift probabilities based on χ 2 minimization and/or through a Bayesian frame-work (e.g., Ben´ ıtez 2000; Bolzonella et al. 2000; Le Borgne &amp; Rocca-Volmerange 2002; Ilbert et al. 2006; Rowan-Robinson et al. 2008; Brammer et al. 2008), although machine learning methods are also being utilized (see Salvato et al. 2018, and references therein).

Despite the considerable success of many previously released photoz codes, a notable concern among them is that the SED templates utilized can often be combined in an arbitrary manner that may not be physically realistic in terms of the properties that would be inferred for the galaxy (e.g., stellar mass ( M ∗ ), star formation rate (SFR), dust attenuation ). 1 Indeed, this is the primary reason that most photoz codes attempt to constrain only the redshift and perhaps a couple other physical properties, if any. A common approach in studies of galaxy evolution is to input the z phot value from photoz codes into separate codes designed specifically to constrain physical properties (e.g., da Cunha et al. 2008; Leja et al. 2017; Boquien et al. 2019) and in doing so often ignore entirely the uncertainty of z phot , or include it through an indirect manner (e.g., Kriek et al. 2009; Johnston et al. 2015). Any z phot uncertainty will translate into additional uncertainty in all luminositydependent quantities (e.g., M ∗ , SFR, total dust luminosity ( L dust )). Therefore, in this type of approach the uncertainty values for galaxy properties will always be underestimated.

Another detail worth mentioning is that most photoz codes utilize data only in the ultraviolet (UV) to nearinfrared (NIR ) wavelength range to constrain the pho2 tometric redshift. Extending the wavelength coverage available in the analysis adds additional leverage in determining z phot and can also help resolve various degeneracies that arise in SED fitting (e.g., Lyman vs. Balmer break or V -band dust attenuation vs. redshift degeneracy, A V -z ; Dunlop et al. 2007; da Cunha et al. 2015).

These degeneracies arise because z , stellar age, A V , and

1 Attenuation is the combination of extinction, scattering of light into the line of sight by dust, and geometrical effects due to the star-dust geometry (e.g., Charlot &amp; Fall 2000; Calzetti 2001). Extinction is the absorption and scattering of light out of the line of sight by dust and has no dependence on geometry (e.g., Fitzpatrick 1999; Draine 2003).

2 We adopt the boundary between near-IR and mid-IR to be 5 µ m. This corresponds to the typical wavelength where the dust emission begins to dominate over stellar emission in the SED of a star-forming galaxy.

metallicity can have similar effects on the observed color of the UV-NIR SED. These effects can be disentangled using observational data of the thermal emission from dust in the mid-IR through (sub-)mm wavelength region (or also radio). In addition, assumptions of dust attenuation have a large impact on physical properties derived from SED modeling and therefore it is crucial to incorporate the full spectral range simultaneously for self-consistency whenever possible. As a caveat, it is important to note that active galactic nuclei (AGN) can significantly alter the SEDs of galaxies and this will impact the reliability of derived quantities if the AGN component is not accounted for in the fitting procedure.

We have developed an extension of the widely utilized spectral fitting code Multiwavelength Analysis of Galaxy Physical Properties ( MAGPHYS ; da Cunha et al. 2008, 2015) that enables robust characterization of z phot and numerous physical properties simultaneously in a self-consistent and physically motivated manner. This extension will be referred to throughout the text as ' MAGPHYS+photo -z ' . 3 The advantage of this approach over previous photoz methods is the consistent incorporation of the z phot uncertainties into the uncertainties of all physical properties that are estimated. Similar to previous versions of the MAGPHYS code, MAGPHYS+photo -z simultaneously models the emission by stellar populations with the attenuation and emission by dust in galaxies based on the assumption of energy balance. We note that similar methodologies have been employed to develop other spectral fitting codes that model the full SED from UV to millimeter (mm) wavelengths (e.g., Leja et al. 2017; Boquien et al. 2019), with some also being able to constrain z phot (e.g., Han &amp; Han 2014; Chevallard &amp; Charlot 2016). The reliability of MAGPHYS in recovering accurate physical properties is demonstrated in its release paper (da Cunha et al. 2008) and has recently been shown to work well on spatially resolved scales of /greaterorsimilar 1 kpc (Smith &amp; Hayward 2018). A preliminary version of MAGPHYS+photo -z was demonstrated in da Cunha et al. (2015), however this was limited to the application of a small sample of sub-mm galaxies and is updated considerably in this work to be reliable for a broader range of galaxies. In this paper we outline a description of the code and demonstrate its ability to accurately constrain photometric redshifts and galaxy properties, together with all of their uncertainties, in a robust and reliable manner.

As a final point, it is worth emphasizing that MAGPHYS+photo -z is not intended to replace existing

3 All versions of the MAGPHYS code are publicly available online at www.iap.fr/magphys.

stand-alone photoz codes when the primary parameter of interest is the photometric redshift because those codes run significantly faster and can be 'tuned' for higher redshift precision and accuracy than our code. Instead, MAGPHYS+photo -z is primarily designed for determining physical properties of galaxies with the added flexibility to incorporate photoz estimates and its uncertainties into the property uncertainties. Additionally, our code is better suited for studying dusty star-forming galaxies for which IR data can provide improved photometric constraints over traditional codes, especially in instances when only upper limits are available at observer-frame UV-optical wavelengths.

This paper is organized as follows: Section 2 describes the MAGPHYS+photo -z code, Section 3 presents the observed sample used to test the code, Section 4 outlines the results of applying the code to galaxies in the COSMOS field, Section 5 discusses additional tests of MAGPHYS+photo -z and a comparison to a commonly adopted photoz code, and Section 6 summarizes the main conclusions of the paper. A detailed description of the updated dust attenuation prescription used in MAGPHYS+photo -z and the characterization of the effective dust attenuation curves for galaxies at 0 1 . /lessorsimilar z /lessorsimilar 3 will be presented in a companion paper (Battisti et al. in prep). In a Throughout this work we adopt a Λ-CDM cosmological model, H 0 = 70 km/s/Mpc, Ω M = 0 3, . Ω Λ = 0 7. .

## 2. MAGPHYS+PHOTOz DESCRIPTION

MAGPHYS (da Cunha et al. 2008, 2015) is a SED-fitting code designed to self-consistently determine galaxy properties based on an energy-balance approach using rest-frame UV through radio photometry in a Bayesian formalism. We refer the reader to release papers above for a detailed explanation of the MAGPHYS code and its methodology. The MAGPHYS+photo -z code is based on the ' MAGPHYS highz ' extension presented in da Cunha et al. (2015). We outline here a summary of the primary differences between highz and photoz versions relative to the original code (da Cunha et al. 2008):

- · The prior on the star-formation history (SFH) is modified to be more appropriate for highz galaxies. This SFH rises linearly at early ages and then declines exponentially, whereas before it was only an exponential declining function (both versions include random bursts of star formation superimposed onto the continuous SFH).
- · The range of the dust optical depth prior is broader to reflect the higher optical depths observed in highz galaxies.
- · The prior for the equilibrium dust temperature is broader to reflect the wider range in dust temperatures observed in highz sub-mm galaxies.
- · A prescription for intergalactic medium (IGM) absorption in the ultraviolet is added. In the highz version, the prescription from Madau (1995) is adopted. For the photoz version, we adopt the more recent prescription of Inoue et al. (2014).
- · For the photoz version, we introduce an additional component in the attenuation curve for the diffuse ISM to characterize additional attenuation due to a 2175 ˚ feature (details presented below). A

Regarding the IGM prescription, we tested utilizing both IGM prescriptions on the COSMOS galaxies used in this study and found that it had a minor effect on the values of z phot for the majority of cases. We attribute the minor differences to the fact that for this dataset the typical uncertainties in the rest-frame far-UV are comparable to or larger than the differences that arise between these two IGM prescriptions ( ∼ 10%; see Figure 4 of Inoue et al. 2014). In addition, we impose a minimum photometric uncertainty of 10% to each band (to mitigate over-fitting issues and potential filter zeropoint offsets) that also acts to reduce z phot differences between these prescriptions. However, we note that differences will become more important with increased photometric accuracy and/or finer photometric sampling of the far-UV region. It is also worth noting that the actual IGM absorption will be stochastic in nature, which is not accounted for in our current prescription, and this can introduce small offsets in z phot estimates (e.g., Brinchmann et al. 2017). Below we present an overview of the models and methodology implemented in MAGPHYS+photo -z .

The choice to adopt a minimum photometric uncertainty of 10% to each band warrants additional discussion. The primary motivation in this choice is driven by the fact that systematic offsets are often found between different photometric datasets and are typically of order 10% (see also Appendix B). Such differences can arise from differences in methodology to obtain the photometry or in adopted flux zeropoints. In some photoz codes, these effects can be accounted for by adopting corrections for each band that minimize residuals between the photometry and the models for galaxies with spectroscopic redshifts. However, this approach cannot be adopted by MAGPHYS+photo -z by virtue of our desire to characterize the physical properties because these offsets have the same effect as altering the model SEDs (hence affecting the derived properties). We tested utilizing lower minimum uncertainties and find that this

leads to significantly underestimated z phot uncertainties (discussed further in Section 4.1), which in turn leads to corresponding underestimates of property uncertainties relative to the 'true' value from standard MAGPHYS runs (i.e., fixed to the z spec values; see Section 4.2).

The stellar emission (dominant in the UV-NIR regime) of each model is calculated such that the luminosity per unit wavelength emerging at time t from a model galaxy is expressed as:

$$L _ { \lambda } ^ { \text{em} } ( t ) = \int _ { 0 } ^ { t } d t ^ { \prime } \Psi ( t - t ^ { \prime } ) \, l _ { \lambda } ^ { \text{SSP} } ( t ^ { \prime }, Z ) \, \exp [ - \hat { \tau } _ { \lambda } ( t ^ { \prime } ) ] \,, \ \ ( 1 ) \quad \ \text{As} \\ \quad \ \text{the}.$$

where l SSP λ ( t , Z ′ ) is the luminosity emitted per unit wavelength per unit mass by a simple stellar population (SSP) of age t ′ and metallicity Z , Ψ( t -t ′ ) is the star formation rate evolution with time (i.e. the star formation history), and ˆ ( τ λ t ′ ) is the effective absorption optical depth seen by stars of age t ′ . The SSP emission is computed using the spectral population synthesis models of Bruzual &amp; Charlot (2003), with a Chabrier (2003) initial mass function. We adopt a uniform prior in metallicity from 0.2 to 2 times solar.

Nebular emission lines are currently not implemented in MAGPHYS . This should have a minimal impact for general application to most massive galaxies when utilizing broadband photometry (see Section 4.1.2). However, we expect the impact of emission lines to become more important on photomerty in the case of low-mass, high-sSFR galaxies. Implementing nebular emission into MAGPHYS and MAGPHYS+photo -z is planned for a forthcoming release.

The dust attenuation, as defined by the 'effective' absorption optical depth (Charlot &amp; Fall 2000) of the dust as seen by stars, ˆ , is given by: τ λ

$$\hat { \tau } _ { \lambda } ( t ^ { \prime } ) = \begin{cases} \hat { \tau } _ { \lambda } ^ { \text{BC} } + \hat { \tau } _ { \lambda } ^ { \text{ISM} } & \text{for $t^{\prime}\leq t_{BC}$}, \\ \hat { \tau } _ { \lambda } ^ { \text{ISM} } & \text{for $t^{\prime} > t_{BC}$}, \end{cases} \quad ( 2 ) \quad \text{$e$} \\ \text{where $\hat{\tau}_{\lambda}^{\text{BC}$ is the effective attenuation optical depth of} } \quad \text{$f$} \quad \text{$d$}.$$

where ˆ τ BC λ is the effective attenuation optical depth of dust in stellar birth clouds, ˆ τ ISM λ is the effective attenuation optical depth in the diffuse ISM, and t BC /similarequal 10 7 yr.

For the diffuse ISM attenuation curve, we utilize an additional component to account for attenuation from a 2175 ˚ A feature. The 2175 ˚ A absorption bump is a prominent feature in the Milky Way (MW) extinction curve (e.g., Draine 2003), but this feature is typically much weaker in strength or completely absent in dust attenuation curves 4 (e.g., Calzetti et al.

4 The additional scattering and geometric effects at play in dust attenuation act to reduce the overall strength of the 2175 ˚ A fea-

1994; Noll et al. 2009; Wild et al. 2011; Buat et al. 2012; Kriek &amp; Conroy 2013; Reddy et al. 2015; Scoville et al. 2015; Salmon et al. 2016; Battisti et al. 2017; Salim et al. 2018) and for this reason it is often excluded in SED modeling (Charlot &amp; Fall 2000; da Cunha et al. 2008). We find that this feature is necessary to reduce systematic residuals between the observations and models in standard MAGPHYS , with an average bump strength of ∼ 30% the MW value being necessary for IR-detected galaxies from 0 1 . /lessorsimilar z /lessorsimilar 3 (Battisti et al. in prep.). As will be discussed in Section 5.3, we also find that the lack of a parameter accounting for additional attenuation from the 2175 ˚ A feature introduces a subtle systematic underestimate of z phot in MAGPHYS+photo -z . Some photoz codes allow for possible 2175 ˚ A absorption by considering fits based on multiple attenuation/extinction curves, which generally acts to improve the quality of fits (e.g., Ilbert et al. 2009). It is also worth noting that the need for this feature is sometimes avoided in other photoz codes through the use of zeropoint offsets or template corrections, which are not performed in MAGPHYS+photo -z .

Here we briefly summarize implementation of the 2175 ˚ absorption feature that will be fully detailed in A Battisti et al. (in prep.). We make the assumption that this feature follows a behavior similar to that of the MWextinction curve, which is well characterized using a Lorentzian-like Drude profile (e.g., Fitzpatrick &amp; Massa 2007):

$$D ( E _ { b }, \lambda ) = \frac { E _ { b } ( \lambda \, \Delta \lambda ) ^ { 2 } } { ( \lambda ^ { 2 } - \lambda _ { 0 } ^ { 2 } ) ^ { 2 } + ( \lambda \, \Delta \lambda ) ^ { 2 } } \,, \quad \quad ( 3 )$$

where λ 0 is the central wavelength of the feature, ∆ λ is its FWHM, and E b is an amplitude constant that defines the bump strength. The average MW extinction curve has values of λ 0 = 2175 8 ˚ , ∆ . A λ = 470 ˚, and A E b = 3 3 (Fitzpatrick 1999). . This E b value refers to the amplitude of the Drude profile in terms of the total-toselective extinction curve k λ ≡ A /E B λ ( -V ). However for our purposes, the Drude profile is defined in terms of normalized optical depth, τ λ /τ V (Charlot &amp; Fall 2000), which we denote as E ′ b to avoid confusion. The relationship between the two versions of the bump strength is the following:

$$E _ { b } ^ { \prime } = E _ { b } / R _ { V } ^ { \text{ISM} } \,,$$

where R ISM V is the total-to-selective attenuation in the V band from the diffuse ISM (note that R V = k V ). For comparison to dust curves that do not utilize two components (birth cloud and ISM), one can simply adopt

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-311be6be-45f3-4ab8-9ceb-d87b1edfd922.jpg)

Figure 1. Prior for the 2175 ˚ feature bump strength ( A E ′ b , see eq 3 and 4; Battisti et al. in prep.) and redshift ( z ; da Cunha et al. 2015) utilized in MAGPHYS+photo -z . The prior distributions for all other parameters are the same as outlined in da Cunha et al. (2015).

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-9cb7031f-4252-4353-9e7c-57ca5468d990.jpg)

R ISM V = R V . For example, the MW extinction curve has a value of E ′ b = 1 06 ( . R V = 3 1; Fitzpatrick 1999). .

The attenuation curve of the birth clouds remains unchanged from previous versions of MAGPHYS ,

$$\hat { \tau } _ { \lambda } ^ { \text{BC} } = \left ( 1 - \mu \right ) \hat { \tau } _ { V } \left ( \lambda / 5 5 0 0 \AA \right ) ^ { - 1. 3 }, \quad \ \left ( 5 \right ) \quad \ \ 2 \right |$$

where ˆ τ V is the effective V -band optical depth seen by stars younger than t BC in the birth clouds and µ is the fraction of ˆ τ V seen by stars older than t BC (i.e., stars in the diffuse ISM component, µ = ˆ τ ISM V / τ (ˆ BC V + ˆ τ ISM V )). The updated attenuation curve characterizing the diffuse ISM is:

$$\hat { \tau } _ { \lambda } ^ { \text{ISM} } = \mu \, \hat { \tau } _ { V } \left [ ( \lambda / 5 5 0 0 \AA ) ^ { - 0. 7 } + D ( E _ { b } ^ { \prime }, \lambda ) \right ], \quad ( 6 ) \quad \text{ use}$$

where, the central wavelength and FWHM of the 2175 ˚ A feature are fixed to the MW value and only the amplitude defining the bump strength, E ′ b , is free to vary within the code. The distribution of the prior for E ′ b was chosen based on the observed strength inferred from intermediate-band data of galaxies in COSMOS (Battisti et al. in prep.) and is shown in Figure 1.

The dust emission models (dominant in the mid-IRsub-mm regime) combine contributions from four components: PAHs and hot dust emitting in the mid-IR, and warm and cold dust components in thermal equilibrium that emit in the far-IR to sub-mm. For the energy balance process within the code, these four components are subdivided into those associated with the birth cloud component (PAHs+hot dust+warm dust) and those associated with the diffuse ISM component (PAHs+hot dust+warm dust+cold dust) and are required to match the energy lost by the attenuation in each component at UV-NIR wavelengths.

The radio component is modeled based on assuming a far-infrared/radio correlation ( q ; Yun et al. 2001), and fixed slopes and relative contributions for the thermal and non-thermal radio emission (following Dale &amp; Helou

2002; see da Cunha et al. 2015 for details). For the analysis in this paper, we do not include radio data because the assumption of a fixed q with redshift will result in the radio data having little power in constraining z phot when far-IR data are also available, as is the case for our chosen samples. However, it is possible to include radio data and it will generally act to improve the overall constraints of various physical properties in MAGPHYS+photo -z , especially when far-IR data are unavailable.

The predicted fluxes of the user-specified filter set for each model (stellar and dust+radio) are then calculated for redshifts in the range 0 1 . &lt; z &lt; 8 0. . The assumed prior for the redshift distribution of the models is shown in Figure 1. This redshift prior is optimized to avoid oversampling unlikely regions of redshift space for application to deep far-IR/sub-mm surveys for which the distribution of galaxy number counts as a function of redshift has a similar shape (e.g., Zavala et al. 2014; da Cunha et al. 2015). We note that the chosen redshift prior is not well suited for application of MAGPHYS+photo -z to very low-redshift ( z /lessorsimilar 0 4) or very . high-redshift ( z /greaterorsimilar 7 5) galaxies because very few mod-. els are generated at these redshifts. As a result, any runs that return z phot values in these redshift regimes will be unreliable and we recommend that they not be utilized in subsequent analysis. Our model stellar ages are required to be younger than the age of the Universe at a given redshift. For each redshift, the predicted model flux at each band is computed by first applying the appropriate IGM absorption prescription to the stellar emission at that redshift and then convolving the total model SED (stellar+dust+radio; matched via energy balance) in the observed-frame with the filter response functions. We then compare the observed fluxes of our galaxies in all the observed bands with the predicted model fluxes by computing the χ 2 goodness-of-fit for each model in our library (defined in da Cunha et al. 2008). Upper limits are included in the χ 2 estimate by setting the flux to zero and adopting the upper limit value as the flux uncertainty.

Finally, we build likelihood distributions of each parameter in our model, including the redshift, by marginalizing the probability of each model P ∝ exp( -χ / 2 2) over all other model parameters. We take our estimates of each parameter to be the median of its likelihood distribution, and the 1 σ confidence range to be the 16th to 84th percentile range.

## 3. DATA AND MEASUREMENTS

To characterize the reliability of MAGPHYS+photo -z , we must utilize a large sample of galaxies with spectroscop-

ically derived redshifts ( z spec ) over a large redshift range that we can compare to our derived values of z phot . For the purpose of this code it is also desirable to use a galaxy sample with extensive multi-wavelength photometric data that spans the full range from UV to submm. For our analysis, we utilize the COSMOS field (Scoville et al. 2007; Capak et al. 2007) because it meets all of these requirements and is unparalleled in terms of the breadth of spectroscopic and multi-wavelength photometric data that are available from numerous telescope facilities. This field has a wealth of IR photometry available, which allows full exploitation of the multiwavelength modeling capability of MAGPHYS . We use two photometric+spectroscopic catalogs of galaxies in the COSMOS field that are optimized for different redshift ranges: the first are part of the Galaxy And Mass Assembly (GAMA) survey and the second are produced by the COSMOS team. Below we provide a brief description of these catalogs and our method for selecting the galaxy samples used for the analysis.

## 3.1. GAMA - G10 Sample

The GAMA survey compiled a highly complete multiwavelength photometric (Driver et al. 2011) and spectroscopic sample of galaxies (Baldry et al. 2010; Robotham et al. 2010; Hopkins et al. 2013) covering 280 deg 2 especiall in three equatorial (G09, G12 and G15) and two southern (G02 and G23) regions, as well as a subset of the COSMOS field (G10), although the latter utilizes previously obtained spectroscopy from the zCOSMOS survey (Lilly et al. 2007, 2009). For this study we use only the G10 region, for which the photometric catalog is described in Andrews et al. (2017) and the spectroscopic catalog is described in Davies et al. (2015).

The catalog of Andrews et al. (2017) contains data from the GALEX , Canada-France-Hawaii telescope (CFHT), Subaru, UltraVista, Spitzer , and Herschel that span the full UV to sub-mm wavelength range and is summarized in Table 1. The photometry is aperturematched utilizing the Lambda-Adaptive Multi-Band Deblending Algorithm in R ( LAMBDAR ; Wright et al. 2016) algorithm. The provided photometry is already corrected for Galactic extinction for all bands from FUV to K s using E B ( -V ) values from the Schlegel et al. (1998) Milky Way dust maps and the extinction curve values listed in Andrews et al. (2017, see their Table 3).

For our parent sample of spectroscopic galaxies, we follow the recommended selection criteria of Z BEST &gt; 0 0001, . Z USE &lt; 3, and STAR GALAXY CLASS = 0 (Davies et al. 2015). This selection provides a reduced sample of 20,364 objects. We further refine this sample to only consider galaxies at z spec &gt; 0 4 with . S/N &gt; 3 (signal-to-noise) in any Spitzer /MIPS, or Herschel band (i.e., requiring at least one detection in the mid-IR to sub-mm wavelength range), which leaves 2,542 galaxies at 0 4 . &lt; z /lessorsimilar 1 6. . We note that the IR-detection criteria tends to select dustier galaxies, on average, in the spectroscopic sample, but that the amount of reddening ( A V ) can vary significantly (also, A V is typically larger for higher redshifts, and vice versa). A test of the code on galaxies without this restriction is presented in Section 5.4.

## 3.2. COSMOS2015 &amp; Super-Deblended Sample

To extend the redshift range in our analysis, we utilize the latest COSMOS master spectroscopic catalog (curated by M. Salvato for internal use within the COSMOS collaboration), together with the COSMOS2015 (Laigle et al. 2016) and 'Super-deblended' (Jin et al. 2018) photometric catalogs. These catalogs combine data from numerous surveys (see release papers for individual surveys utilized) in a homogeneous manner. The COSMOS2015 catalog provides photometry for the UV through mid-IR wavelength range from the GALEX , CFHT, Subaru, UltraVista, and Spitzer /IRAC. The COSMOS2015 photometric catalog is corrected for Galactic extinction for all bands from NUV to K s using the provided E B ( -V ) values based on the Schlegel et al. (1998) Milky Way dust maps and adopting the same extinction curve values as used in G10 for consistency (Andrews et al. 2017). We adopt total flux values (3 ′′ + aperture correction) using the prescription described in Laigle et al. (2016), because these are better suited for combining with the total flux measurements of the IR data in the Super-deblended catalog (Jin et al. 2018). The Super-deblended catalog extends the wavelength coverage of COSMOS sources for the mid-IR through radio wavelength range from the Spitzer /MIPS, Herschel , SCUBA2, AzTEC, MAMBO, and Very Large Array (VLA). Jin et al. (2018) use nearIR and radio priors to overcome severe Herschel sub-mm source blending issues and achieve deeper detections (framework described in Liu et al. 2018). The bands utilized from the COSMOS2015+Super-deblended catalogs are summarized in Table 1. These catalogs have also been cross-matched with X-ray sources from the Chandra COSMOS catalogs (Elvis et al. 2009; Civano et al. 2012, 2016; Marchesi et al. 2016) and the XMM/Newton Wide-Field Survey in the COSMOS Field (Hasinger et al. 2007; Brusa et al. 2007, 2010; Cappelluti et al. 2009). For brevity, we will refer to the combined COSMOS2015+Super-deblended catalogs

as 'C15+SD catalog' throughout the remainder of the paper.

For our parent sample of spectroscopic galaxies, we utilize cases with robust spectroscopic redshifts (Quality flag Q f = 3 or 4, as defined in zCOSMOS; Lilly et al. 2009). The COSMOS master catalog contains many duplicate observations and these are remedied in the manner described below. First, if all duplicates have z spec within 0 01 of each other, we simply adopt the first value . and remove all other duplicate cases, as these differences are below the expected precision of our photoz solutions. If the z spec of the duplicates disagree by more than 0 01, . we give preference to cases of 'very secure redshifts' ( Q f = 4) over 'secure redshifts' ( Q f = 3 ). In instances of disagreement between cases with similar Q f , we resolve this in the following manner: 1) duplicate cases with z spec solutions within 0.05 of each other are given a higher ranking relative to single outliers (here we consider all z spec regardless of Q f to determine ranking of higher Q f cases); and 2) higher spectral resolution ( R ) observations are ranked higher than lower resolution observations (with grism data having the lowest ranking). If after considering these two options there are still duplicates of equal rank, we rank newer observations higher than older observations. After resolving duplicate cases, we are left with a parent sample of 34,785 galaxies. We further refine this sample to only consider galaxies at z spec &gt; 1 0 with . S/N &gt; 3 in any band from Spitzer /MIPS, Herschel , SCUBA, AZTEC, or MAMBO, which leaves 2,133 galaxies at 1 ≤ z &lt; 6. For situations where the same galaxy is present in both the G10 and C15+SD catalogs, we adopt the G10 photometry because the LAMBDAR approach is designed to provide self-consistent photometry over the full UV to sub-mm range (Wright et al. 2016). This removes 130 IR-detected galaxies from the C15+SD catalog, leaving a sample of 2,003 galaxies.

## 3.3. AGN Identification

We identify and remove AGN from the main analysis because current public versions of MAGPHYS are intended only for purely star-forming galaxies (i.e., it does not include AGN contribution to the SEDs) and therefore properties derived for AGN may be incorrect. Introducing AGN models into MAGPHYS is planned for a forthcoming release ( MAGPHYS+AGN ; application of a preliminary version is shown in Chang et al. 2017). AGN are identified using several techniques, including: 1) the Spitzer /IRAC color selections of Donley et al. (2012); 2) the Spitzer -Herschel color selections of Kirkpatrick et al. (2013); 3) the radio-NIR color selection of Seymour et al. (2008); and 4) sources with any

Table 1. COSMOS filter set and Galactic extinction curve values.

| Band        | Facility/Instr.         | λ eff ( µ m)   | k ( λ ) a   | Catalog b   |
|-------------|-------------------------|----------------|-------------|-------------|
| FUV         | GALEX                   | 0.1516         | 8.376       | G10         |
| NUV         | GALEX                   | 0.2267         | 8.741       | G10, C15    |
| u ∗         | CFHT/Mega-Prime         | 0.3750         | 4.690       | G10, C15    |
| IA427       | Subaru/SC               | 0.42635        | 4.260       | G10, C15    |
| B           | Subaru/SC               | 0.4460         | 4.039       | G10, C15    |
| g ′         | Subaru/SC               | 0.4480         | 3.738       | G10         |
| IA464       | Subaru/SC               | 0.46351        | 3.843       | G10, C15    |
| IA484       | Subaru/SC               | 0.48492        | 3.621       | G10, C15    |
| IA505       | Subaru/SC               | 0.50625        | 3.425       | G10, C15    |
| IA527       | Subaru/SC               | 0.52611        | 3.264       | G10, C15    |
| V           | Subaru/SC               | 0.5484         | 3.147       | G10, C15    |
| IA574       | Subaru/SC               | 0.57648        | 2.937       | G10, C15    |
| IA624       | Subaru/SC               | 0.62329        | 2.694       | G10, C15    |
| r ′         | Subaru/SC               | 0.6295         | 2.586       | G10, C15    |
| IA679       | Subaru/SC               | 0.67811        | 2.430       | G10, C15    |
| IA709       | Subaru/SC               | 0.70736        | 2.289       | G10, C15    |
| IA738       | Subaru/SC               | 0.73615        | 2.150       | G10, C15    |
| i ′         | Subaru/SC               | 0.7641         | 1.923       | G10, C15    |
| IA767       | Subaru/SC               | 0.76849        | 1.996       | G10, C15    |
| IA827       | Subaru/SC               | 0.82445        | 1.747       | G10, C15    |
| z ′         | Subaru/SC               | 0.9037         | 1.436       | G10         |
| z ++        | Subaru/SC               | 0.9037         | 1.436       | C15         |
| Y           | Subaru/HSC              | 0.9791         | 1.298       | C15         |
| Y           | VISTA/VIRCAM            | 1.021          | 1.211       | G10, C15    |
| J           | VISTA/VIRCAM            | 1.254          | 0.871       | G10, C15    |
| H           | VISTA/VIRCAM            | 1.646          | 0.563       | G10, C15    |
| K s         | VISTA/VIRCAM            | 2.149          | 0.364       | G10, C15    |
| ch1         | IRAC/ Spitzer           | 3.550          | · · ·       | G10, C15    |
| ch2         | IRAC/ Spitzer           | 4.493          | · · ·       | G10, C15    |
| ch3         | IRAC/ Spitzer           | 5.731          | · · ·       | G10, C15    |
| ch4         | IRAC/ Spitzer           | 7.872          | · · ·       | G10, C15    |
| 24 µ m      | MIPS/ Spitzer           | 23.68          | · · ·       | G10, SD     |
| 70 µ m      | MIPS/ Spitzer           | 71.42          | · · ·       | G10         |
| 100 µ m     | PACS/ Herschel          | 100            | · · ·       | G10, SD     |
| 160 µ m     | PACS/ Herschel          | 160            | · · ·       | G10, SD     |
| 250 µ m     | SPIRE/ Herschel         | 250            | · · ·       | G10, SD     |
| 350 µ m     | SPIRE/ Herschel         | 350            | · · ·       | G10, SD     |
| 500 µ m     | SPIRE/ Herschel         | 500            | · · ·       | G10, SD     |
| 850 µ m     | SCUBA-2/JCMT            | 850            | · · ·       | SD          |
| 1.1mm 1.2mm | AzTEC/ASTE MAMBO-2/IRAM | 1100 1200      | · · · · · · | SD SD       |

a Extinction curve values adopted as in Table 3 of Andrews et al. (2017, and references outlined therein)

b Denotes the catalog(s) that include this band. G10=GAMA/G10 catalog (Andrews et al. 2017), C15=COSMOS2015 catalog (Laigle et al. 2016), SD=Superdeblended catalog (Jin et al. 2018)

X-ray detection. We note that for the color selection criteria each photometric band used in a given color is required to have signal-to-noise ratio of S/N &gt; 3. These methods identify 179 AGN (7.0%) in the G10 sample and 117 AGN (5.8%) in the C15+SD sample. This leaves a final sample of 2,363 and 1,886 galaxies in the G10 and C15+SD catalogs, respectively, for our analysis.

In practice it is not always feasible to identify AGN when limited data is available. In addition, even when various selection methods can be implemented, they can often miss some of the AGN population. As a result, we separately discuss the reliability of the z phot estimates for our AGN in Appendix A.

## 4. APPLICATION OF MAGPHYS+PHOTOz TO COSMOS

## 4.1. Photometric Redshifts

We perform MAGPHYS+photo -z runs on all galaxies in our GAMA/G10 and C15+SD samples using two filter sets: 1) using only the broadband filters, and 2) using both the broad- and intermediate-band filters (see Table 1). The choice of using both of these filter sets allows us to examine the influence of using different filters on the results. An example of a MAGPHYS+photo -z run on the broadband data for a galaxy in the C15+SD sample is shown in Figure 2, together with likelihood distributions for some of the derived properties.

## 4.1.1. Using Only Broadband Data

The photometric vs. spectroscopic redshift distribution of the full G10 and C15+SD samples using broadband-only data are shown in Figure 3, Left . Cases where the z phot distribution has &gt; 2% of its probability located at a secondary peak value (i.e., degenerate z phot solutions) are flagged as being 'multi-peak z phot .' These cases are considered less reliable and we make this distinction for the purpose of subsequent analysis. We find that the fraction of multi-peak z phot cases for our G10 and C15+SD samples are 1.5% and 3.1%, respectively. We also denote the median values for both samples and it can be seen that the overall agreement between the z phot and z spec values are excellent.

Here we define some commonly adopted metrics for characterizing the performance of photoz results and give the corresponding values found for MAGPHYS+photo -z using only broadband data. The precision, or scatter of the data, is characterized using the normalized median absolute deviation (NMAD; Hoaglin et al. 1983), defined as

$$\sigma _ { N M A D } = 1. 4 8 \times \text{median} \left ( \left | \frac { \Delta z - \text{median} ( \Delta z ) } { 1 + z _ { \text{spec} } } \right | \right ) \,, \ ( 7 ) \quad \text{$z_{ph}$} \quad \text{$tiv} \quad \text{$\quad$}$$

where ∆ z = z phot -z spec . The precision of the G10 and C15+SD samples are σ NMAD = 0 046 and 0 032, respec-. . tively. We define a catastrophic failure, also referred to as an outlier, as a source with ∆ z/ (1 + z spec ) &gt; 0 15. . The fraction of catastrophic failures,

$$\eta = N ( \Delta z / ( 1 + z _ { s p e c } ) > 0. 1 5 ) / N ( \text{total} ) \,, \quad ( 8 )$$

for the G10 and C15+SD samples are η = 4 5% and . 3 7%, respectively. . The accuracy of the code is quantified as the systematic deviation, or bias, from z phot = z spec using the median value of the population not considered to be catastrophic failures,

$$\begin{array} { c } z _ { \text{-bias} } = \text{median} ( \Delta z / ( 1 + z _ { \text{spec} } ) ) \\ & \text{for $\Delta z/(1+z _ { \text{spec} } ) < 0.15$} \,. \end{array} \ ( 9 )$$

The redshift-normalized median value for the G10 and C15+SD samples are z -bias = 0 000 and . -0 004, respec-. tively, and are below the achieved precision ( σ NMAD ). The values of the main metrics for each catalog are summarized in Table 2. We find that ∆ z/ (1 + z spec ) &lt; . 0 05 for 69% and 81% of the G10 and C15+SD samples, respectively. The fraction increase to 91% and 94%, respectively, for cases with ∆ z/ (1 + z spec ) &lt; . 0 1.

The fraction of cases for which the z phot 1 σ confidence ranges are in agreement with z spec is 31% and 62% for the G10 and C15+SD samples, respectively (58% and 85% within 2 σ agreement). This indicates that we underestimate the z phot uncertainties for our galaxies, particularly for the G10 sample at lower redshifts. Underestimation of z phot uncertainties is a common problem among photoz codes (e.g., Dahlen et al. 2013). In our case, we believe this effect is mainly due to over-fitting the extensive number of available filters with high S/N (despite imposing a minimum 10% photometric uncertainty to each band) where systematic effects in the photometry can be problematic (e.g., zeropoint issues; Dahlen et al. 2013). At lower redshifts, there are also fewer models for comparison in our library relative to higher redshifts, due to the redshift prior utilized, and this can impact the uncertainty estimates. However, we note that the fraction of cases with 1 σ agreement as a function of redshift for MAGPHYS+photo -z are comparable to other photoz codes that do not utilize redshift priors (see Section 5.4). The error underestimation does not significantly impact the estimates for the physical properties (or their uncertainties) because these cases are typically within ∆ z/ (1 + z spec ) &lt; 0 05, where . z phot uncertainties are less influential on parameter estimates.

Among all catastrophic failure cases, we find that 15% and 21% of them are the 'primary redshift' of multi-peak z phot cases (open circle) for G10 and C15+SD, respectively. For reference, we find that the primary redshift

Figure 2. Top: The upper panel demonstrates the best-fit model from MAGPHYS+photo -z (black line) on broadband data of a randomly selected galaxy in the C15+SD catalog with excellent far-IR sampling. The filled red squares and open black circles are the observed and model photometry, respectively. The uncertainty on the data are shown by the red error bars. The blue line is the predicted unattenuated stellar population SED for the best-fit model. The lower panel shows the residual between the observed and model photometry. Bottom: The two rows show the full likelihood distributions of z phot , stellar mass, star formation rate, dust luminosity, dust mass, mass-weighted stellar age, V -band dust attenuation, 2175 ˚ bump strength ( A E ′ b ), the fraction of ˆ τ V seen by stars older than t BC ( µ ), and the effective dust temperature, respectively. For parameters with priors, we show the assumed prior distribution as a gray histogram. The top right corner of each panel indicates the median-likelihood value and the 16th-84th percentile range.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-d6db8e45-39a9-4092-875e-510f37f65fad.jpg)

Table 2. Summary of photoz metrics (defined in Section 4.1.1) for MAGPHYS+photo -z on COSMOS galaxies.

|         | Broadband-Only   | Broadband-Only   | Broadband-Only   |
|---------|------------------|------------------|------------------|
| Catalog | σ NMAD           | η                | z -bias          |
| G10     | 0.046            | 0.045            | 0.000            |
| C15+SD  | 0.032            | 0.037            | -0.004           |

Broad+Intermediate Bands

Catalog

G10

C15+SD

σ

NMAD

η

z

-bias

0.031

0.027

0.032

0.033

-0.003

-0.010

of multi-peak z phot cases are in agreement (below the catastrophic threshold) for 53% and 75% of these cases in G10 and C15+SD, respectively. This indicates that the multi-peak z phot cases, which make up 2.1% of our total population, have a higher rate of failure than the single peaked solutions, as would be expected, although the reliability of the primary redshift is still reasonable. We also examine the best-fit χ 2 values as an indicator of z phot reliability. For this we consider the distribution of χ 2 for each sample, which depends on the filter set and data quality, and fit a Gaussian distribution to the lower 90% of each population to determine its mean, ¯ , χ 2 and dispersion, σ χ ( 2 ). These fits give

Figure 3. Left: Comparison between the photometric and spectroscopic redshifts for IR-detected galaxies using MAGPHYS+photo -z on broadband data (circles). The 1 σ confidence range of z phot for each galaxy is represented by a gray error bar. Cases with multiple z phot peaks have the primary redshift peak indicated by open circles and a small filled circles to indicate secondary peaks (when the secondary peak is beyond the 1 σ range they are connected by dotted gray lines). The median values of equal-number bins (excluding catastrophic failures) for the GAMA/G10 and C15+SD samples are shown as light blue and orange squares, respectively. Top Right: Redshift accuracy (∆ z /(1+ z spec )) as a function of z spec using broadband data shown in terms of surface density. The redshift scatter ( σ NMAD ), catastrophic failure rate ( η ), and redshift bias (median(∆ z/ (1+ z spec ))) values are shown for each sample at the top of each panel. There is minimal redshift bias at all redshifts examined among these samples. Bottom Right: Redshift accuracy using broad+intermediate band data. There is improvement in σ NMAD when including intermediate bands, but not in the other metrics. Comparing the top and bottom panels (e.g., at z spec /similarequal 0 7) demonstrates that small redshift . biases can be dependent on the filter set.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-25c94f3b-fa9f-46c8-b18c-27e57a2633c9.jpg)

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-57baa297-7d6e-4e23-bd21-c81b18b187cc.jpg)

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-13508c6a-0299-42f4-b16a-e6e1acbb9f52.jpg)

¯ χ 2 G10 = 1 35 and . σ χ ( 2 G10 ) = 0 62, and . ¯ χ 2 C15+SD = 0 51 . and σ χ ( 2 C15+SD ) = 0 23, where the lower values in the . C15+SD sample are primarily due to the lower S/N of the higher redshift data. As expected, we find that the failure rate is higher for cases with high χ 2 values, with 30% and 34% of catastrophic failures having χ 2 &gt; χ ¯ 2 + 4 σ χ ( 2 ) for G10 and C15+SD, respectively. For comparison, the instance rate of χ 2 &gt; χ ¯ 2 +4 ( σ χ 2 ) for our total population is 4.3% and 6.3% for G10 and C15+SD, respectively. High χ 2 values may be indicative of objects for which the current MAGPHYS models are not able to reproduce the observations, such as might be expected if fitting single stars (that might contaminate the catalog) or AGN (see Appendix A). We recommend users of the code to be cautious of MAGPHYS+photo -z re- sults with multi-peaked z phot distributions and/or particularly high χ 2 values relative to the rest of the population because the results for these cases are likely to be less reliable.

We also examine the behavior of the z -bias with photometric quality and galaxy physical properties to identify if there are regimes where the code may be less reliable. In Figure 4, we show the z -bias for our combined sample as a function of Subaru i + apparent magnitude, which is related to the S/N quality, and the median values of M ∗ , SFR, and A V derived using MAGPHYS highz (i.e., fixed to z spec ). We adopt Subaru i + to allow comparison to z phot results presented in Laigle et al. (2016) for the COSMOS2015 catalog (see also Section 5.4). We do not observe any significant trends in z -bias with the

i + apparent magnitude and find comparable dispersions ( σ NMAD /similarequal 0 04) and catastrophic failure rates ( . η /similarequal 4%) for all bins. For the comparison with physical properties, we adopt fixedz spec values because M ∗ and SFR are luminosity dependent (i.e., they depend on z phot ) and the z spec values are a better indication of the 'true' galaxy property (see Section 4.2). Similar to before, we do not observe significant trends in z -bias as a function of M ∗ , SFR, and A V . The comparison with A V indicates that the accuracy does not change substantially with the total amount of dust attenuation, although the precision is dependent on the S/N . The results of this Section demonstrate that MAGPHYS+photo -z is successful in obtaining reliable z phot values over a wide range of redshifts and physical properties.

## 4.1.2. Using Broad+Intermediate Band Data

Now, we consider MAGPHYS+photo -z runs that include the broadand intermediate-band data. As a reminder, emission lines are not included in our models and these can impact observation in narrower filters. For this reason, users should be cautious when utilizing intermediate-band data in MAGPHYS+photo -z . However, doing this allows us to examine how much the z phot results change when they are included and also allows for direct comparison to z phot values determined from an independent code that uses these filters (Section 5.4). The comparison between the photoz results for the broadband-only and broad+intermediate band fits is shown in Figure 3, Right , and includes the metrics that are obtained for each case at the top of each panel. As expected, the precision ( σ NMAD ) shows an improvement when the intermediate bands are included thanks to the better SED sampling. The catastrophic failure rate ( η ) also shows a small decrease for both samples. However, the z -bias becomes slightly worse. Another feature worth noting is that the redshift offsets of the samples as function of z spec between these filter sets are slightly different (e.g., at z spec /similarequal 0 7 the broadband-only . has a slight positive z -bias and the broad+intermediate band case is slightly negative). This is not surprising given that the z phot constraints are dependent on which regions of the SED are sampled and how well the filters sample strong features (in this instance the intermediate bands increase the sampling of the Balmer break). There are a couple slight z -bias dips (e.g., at z ∼ 1 and z ∼ 1 2) that arise for the broad+intermediate-band fits . due to high equivalent width emission lines (in our case arising from [OII](3727 ˚ )) influencing the intermediateA band photometry, which is currently not accounted for in the models.

The current lack of emission lines in the models may decrease the level of z phot precision that can be achieved (higher σ NMAD ; e.g., Ilbert et al. 2009) but does not significantly affect the accuracy ( z -bias) in most cases, although exceptions to the latter may occur for sources with very high equivalent width lines (high specific-SFR, Pacifici et al. 2015). In many instances, sources influenced by strong emission lines tend to have multi-peak z phot solutions in MAGPHYS+photo -z . For now, we recommend users test the effect of removing bands from a fit if they are suspected to be significantly influenced by an emission line (e.g., if a prominent emission line falls on a particular filter at one of the z phot peaks, try rerunning the code for that source without the filter included ( fit=0 in the filter file) to see if there are significant changes).

## 4.2. Physical Properties and Their Uncertainties

In this section we outline the ability of MAGPHYS+photo -z to reliably constrain galaxy physical properties and their uncertainties. As a baseline for this assessment, we compare the properties derived for each galaxy to those of MAGPHYS highz runs where the redshift is fixed to z spec . We expect these fixed-redshift runs to provide the best estimate for the 'true' physical properties. For consistency between the MAGPHYS highz and MAGPHYS+photo -z versions, we adopt the IGM prescription of Inoue et al. (2014) instead of Madau (1995) and also include the 2175 ˚ A feature component in the MAGPHYS highz runs (Battisti et al. in prep.). We utilize the exact same priors for all parameters in both version. All fitting results in these sections use the broadband-only data for the GAMA/G10 and C15+SD samples.

The comparison between MAGPHYS+photo -z and MAGPHYS highz for the derived values of the M ∗ , SFR, L dust , and A V are shown in Figure 5. We distinguish galaxies with poor quality fits in MAGPHYS highz , defined as χ 2 z spec &gt; χ ¯ 2 + 4 σ χ ( 2 ), because these cases are likely to have unreliable property estimates for comparison. These highχ 2 cases comprise 3.7% and 8.6% of the G10 and C15+SD samples, respectively. We also distinguish galaxies with z phot catastrophic failures in MAGPHYS+photo -z because they have drastically different parameter estimates due to the different assumed distances. It is not surprising that many of the cases with poor quality fits in MAGPHYS highz are also catastrophic failures in MAGPHYS+photo -z . Below we summarize the results of comparing well-fit galaxies. We find good agreement between parameter values from each code, with a median difference between the photoz and highz values of 0.00, 0.04, 0.05, and 0.05 for log( M ∗ ),

Figure 4. Redshift accuracy (∆ z /(1+ z spec )) for the entire sample (G10 &amp; C15+SD) as a function of Subaru i + apparent magnitude, which is related to the S/N quality, and the median values of M ∗ , SFR, and A V derived using MAGPHYS highz (i.e., fixed to z spec ). The median values of equal-number bins (excluding catastrophic failures) are shown as purple squares. The redshift scatter ( σ NMAD ), catastrophic failure rate ( η ), and redshift bias (median(∆ z/ (1 + z spec ))) values are similar over the ranges examined and no significant trends are observed.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-df9b244e-8c9e-4f40-afdc-ea684116cb45.jpg)

log(SFR), log( L dust ), and A V , respectively. These values are below the dispersion of the difference, which is 0.10, 0.15, 0.14, and 0.13, respectively. The parameter estimates from both codes are consistent (overlapping within their 1 σ confidence range) for 82%, 73%, 70%, and 74%, respectively.

The largest differences in parameter estimates between the two versions of the code occur from differences between z phot and z spec , as would be expected, and this is demonstrated in Figure 6. The positive trends for M ∗ , SFR, and L dust with the redshift offset are a direct result of these quantities being luminosity-dependent (i.e., an overestimated z will infer larger quantities, and vice versa). The slight negative trend with A V is a result of the degeneracy of this quantity with z phot , because both of these quantities can have similar effects on the observed colors.

A key feature of MAGPHYS+photo -z is the selfconsistent incorporation of photometric redshift uncertainty into the uncertainty of all derived properties. As a demonstration of the importance of this effect, we show the relation between the photometric redshift uncertainty ( ± 2 σ confidence range; difference between 97.5 and 2.5 percentile range) and the uncertainty in a few of the derived physical properties in Figure 7. We use the ± 2 σ confidence range to highlight a larger range of parameter space, but the effective trends are identical for the ± 1 σ ranges. For clarity, we do not include a small fraction of cases where the difference between the ± 2 σ range is zero, which is an artifact of the limited number of models that are in the generated SED libraries (this is most prevalent when models at the extremes of our priors are preferred; see Figure 1). As expected, the uncertainty range for parameters increases dramatically as a result of increases in the z phot uncertainty. By accounting for this ef- fect, MAGPHYS+photo -z provides more realistic uncertainties for physical properties. These uncertainties affect studies relying on photometric redshifts to study galaxy evolution, such as determining galaxy scaling relations and their scatter (e.g., Brinchmann et al. 2004; Tremonti et al. 2004; Speagle et al. 2014; Cappellari 2016; Tacconi et al. 2018).

## 5. DISCUSSION

## 5.1. MAGPHYS+photoz Self-Consistency Test

As a self-consistency test of the code, we perform runs using mock galaxy observation based on MAGPHYS generated SED models. Performing this test allows us to check for any influence that our priors might have on biasing the z phot solutions. The mock observations are constructed using the stellar population and dust emission models generated by MAGPHYS+photo -z for the G10 broadband filter set.

To construct our mock observations, we first randomly select a stellar emission model of input redshift, z in , in the range of 0 4 . &lt; z in &lt; 6. Next, a compatible dust emission model is selected by requiring that the fractional contribution to the total dust luminosity from the diffuse ISM ( f µ ) and birth cloud components (1 -f µ ) of both models agree within 0.01 (i.e., energy balance in each component matches) and also that the redshift of each model be within 0.01. We then assign flux uncertainties and offset that are based on the distribution of values for the broadband data in the G10 catalog. For each filter, we introduce a constant offset in the model flux that is drawn randomly from a Gaussian distribution centered on zero and with a 1 σ of ± 15% of the flux value. These offset values are typical of those found between the observational data and the MAGPHYS+photo -z model fits for the G10 sample and are chosen to result in a best-fit χ 2 distribution that is roughly comparable

Figure 5. Comparison of stellar mass ( M ∗ ; top left ), SFR ( top right ), total dust luminosity ( L dust ; bottom left ), and effective V -band dust attenuation ( A V ; bottom right ) derived from MAGPHYS+photo -z and MAGPHYS highz (i.e., redshift fixed to z spec ). Galaxies with relatively poor quality fits ( χ 2 &gt; 4) in MAGPHYS highz (orange circles) or catastrophic failures in MAGPHYS+photo -z (open red circles) are considered unreliable. For well-fit galaxies (black circles) the agreement is quite good, with median differences that are below the dispersion and with ∼ 70% of values agreeing within their 1 σ confidence range (see Section 4.2). The surface density of the median difference (photoz -highz ) is shown at the bottom of each panel.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-cb22989b-305a-436c-bce9-45b805525cc8.jpg)

to those found for the real observations (¯ χ 2 mock = 1 67; . σ χ ( 2 mock ) = 0 73). . To simulate the detection rates for each filter, we include non-detections in the flux values that are drawn and assigned. Finally, flux error values are assigned to each filter by drawing randomly from the distribution of fractional error values that are observed in the G10 sample. Using the method described above, we construct a catalog of mock broadband observations for 2,000 simulated galaxies.

Figure 8 shows the MAGPHYS+photo -z output redshifts, z out , for the 2,000 mock SEDs. We note that for this test we do not incorporate any redshift dependence to the offset and fractional error values as we are most interested in seeing if there are systematic offsets at any redshift when the data are of comparable quality. For this reason, this test does not reproduce typical observational trends of increasing z phot scatter at higher redshifts. It can be seen that there is excellent agreement over the entire redshift range from 0 4 . &lt; z &lt; 6 with minimal z -bias. The two instances of underestimated z out at z in /similarequal 3 are the result of the Lyman break feature being incorrectly interpreted as a particularly strong 2175 ˚ A feature in a very dusty mock galaxy. The better precision at the highest redshifts is the result of the Lyman

Figure 6. Comparison of the difference in M ∗ , SFR, L dust , and A V (photoz -highz ) as a function of the difference between z phot and z spec . As expected, the largest differences occur for luminosity-dependent quantities.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-a1c22d7e-fd28-47f3-b4cb-28a62fb4d7ae.jpg)

break being very well sampled by the numerous optical filters at unrealistically high S/N . To test if higher uncertainty for the highest redshift mock galaxies makes a difference, we performed a separate test of models at z &gt; 4 with uncertainties increased by a factor of 30 from the previous run and still found no z -bias to be evident. These results demonstrate that the choice of priors, in particular the non-uniform prior for the model redshift distribution (Figure 1), and the fitting method adopted do not introduce significant z -bias in the results.

## 5.2. Influence of IR Filters on photoz Estimates

Given that most photoz codes in the literature use only UV-NIR data, in this section we examine the influence that including the IR data have on constraining z phot in MAGPHYS+photo -z . In particular, we compare the fits obtained using only the UV through NIR filters (FUV-IRAC2; i.e., filters typically included in standalone photoz codes) and only the NIR through sub-mm filters (IRAC1-SPIRE500) relative to the fits when all of the available filters are used. Figure 9 demonstrates the MAGPHYS+photo -z solutions for a G10 galaxy when utilizing these different subsets of filters. In general we find that the UV-optical bands are crucial for precise estimation of z phot whereas having IR-sub-mm bands alone are often not sufficient as z phot tends to have a very broad likelihood distribution and/or have multiple peaks. This limitation is mainly due to the degeneracy in the location of the dust emission peak, because it varies both with T dust and redshift. For example, when using only the IR-sub-mm bands in G10 galaxies with 5 or more bands at 24 µ m or longer with S/N &gt; 3, we find 54% of the median z phot values (similar fraction for best-fit z phot ) are within | ∆ z / | (1 + z spec ) &lt; 0 1, . with 52% of cases having multi-peak z phot solutions. Thus, even for galaxies that sample the far-IR dust peak well, it is difficult to precisely constrain z phot when T dust is allowed to vary. However, if one has finer sampling of the PAH features, as will be possible in the future with JWST , then the ability to constrain z phot from IRonly bands will increase greatly. In addition, for very dusty sources, utilizing upper limits for UV-optical data in addition to IR detections will significantly improve the photometric redshift constraints because in many cases one of the ( A V -z ) degenerate solutions can be ruled out (da Cunha et al. 2015). It is also worth noting that very dusty sources are also much easier to detect at observer-frame (sub-)mm than at other wavelengths owing to the negative K -correction approximately canceling the luminosity distance dimming at z /greaterorsimilar 1 (e.g., Blain &amp; Longair 1993).

It is expected that the inclusion of the IR bands should increase the precision of z phot in our samples, as having a wider wavelength sampling of the SED will always be beneficial and the IR luminosity also provides constraints on the dust attenuation. A comparison of the z phot uncertainties for the G10 and C15+SD samples when using the full (broadband) filter set to those when only using the UV-NIR filters demonstrate that

Figure 7. Comparison between the photometric redshift uncertainty ( ± 2 σ confidence range) and the uncertainty of M ∗ , SFR, L dust , and A V as derived from MAGPHYS+photo -z . As expected, larger photoz uncertainties result in larger parameter uncertainties and are important to account for in studies relying on photometric redshifts to study galaxy evolution. The clumpiness of the A V panel is an artifact of the discretization of this parameter in the code.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-60c97017-7e9d-4ce5-a4f5-da16be7a1e2d.jpg)

the former case has a ± 1 σ confidence range that is slightly lower than the latter, with a median( z (84%)z (16%))=0.075 vs. 0.105, respectively, for G10 and 0.125 vs. 0.155, respectively, for C15+SD. The changes in the values for σ NMAD , η , and z -bias are relatively minor between these runs. It is worth noting that the addition of IR-bands will have a larger impact on the z phot precision in fields where there is sparser and/or shallower coverage at shorter wavelengths. The relatively minor improvement in precision afforded by the addition of IR-bands in the COSMOS field is primarily a testament to its extensive multiwavelength UV-NIR coverage and depth that provide exceptional SED sampling for z phot determination.

Following from the previous discussion, it is also worth briefly highlighting that users should be conscious of the fact that when there is little constraining information for a particular physical property, which can be due to gaps in spectral coverage, the returned posterior probability distribution (or confidence range) will be very broad (often reflecting the prior). As an example, one parameter that is often not well constrained is the total dust mass,

Figure 8. Comparison between the true redshift ( z in ) and photometric redshift ( z out ) for 2,000 mock galaxies using the G10 broadband filters of MAGPHYS models (circles) that also include photometric offsets and uncertainties based on G10 catalog (see Section 5.1). Labels are the same as in Figure 3. The median values of equal-number bins are shown as cyan squares and show no significant systematic biases as a result of our parameter priors or adopted fitting method. The lower panel shows the redshift difference normalized by 1 + z in in terms of surface density.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-a3a84ca5-8a23-48a9-a19f-edbb260eb3b9.jpg)

M dust , as this requires sampling of the Rayleigh-Jeans tail of the dust graybody emission (rest-frame sub-mm wavelengths) because cold dust accounts for the bulk of the mass while warm dust dominates the total infrared luminosity (e.g., Scoville et al. 2016). Another example is the 2175 ˚ bump strength which will always have a A positive value ( E ′ b &gt; 0) when there are no filters sampling that region because of the adopted prior distribution. It is important to account for the full posterior probability distribution when performing an analysis of any of the derived galaxy properties.

## 5.3. Influence of the 2175 ˚ A Feature on Photometric Redshifts of Dusty Galaxies

In this section we outline the effect that the 2175 ˚ A absorption feature has on z phot values when it is not accounted for in the galaxy models. It is worth noting that the influence of this feature on the attenuated SED scales directly with the amount of reddening ( A 2175 = E b · E B ( -V ) ∝ E ′ b · A V ; this is ignoring effects of the filter response), such that the influence on z phot is larger for dustier galaxies at a fixed value of E ′ b . It is worth highlighting that because the bump strength parameter ( E ′ b ) is independent of the total amount of dust reddening ( A V ), there is a degeneracy in the manner that the total attenuation at the wavelength of the feature can be fit (i.e., low E ′ b and high A V vs. the opposite). This issue is mitigated when IR data is available to better constrain A V via energy balance. This also implies that galaxies with higher A V tend to have more reliable estimates for E ′ b because the total bump attenuation becomes more sensitive to small changes in E ′ b .

We run MAGPHYS+photo -z without the prescription for the 2175 ˚ feature but keep every aspect the same (i.e., A here we fix E ′ b = 0; see Section 2) and compare them to our previous results. In Figure 10, we show the difference in the z phot values obtained for our samples as a function of z spec for runs without a bump relative to those when a bump is allowed. It can be seen that the z phot values for runs without the 2175 ˚ feature are sysA tematically lower at most redshifts relative to those for which it is included. The offset depends strongly on the number of filters that probe the 2175 ˚ region, their A FWHM, and their S/N . For example, the u -band is the only broadband filter probing the 2175 ˚ region at A 0 4 . /lessorsimilar z /lessorsimilar 0 6, although weakly because the bump peak . shifts to its effective wavelength at z /similarequal 0 7, and it typ-. ically has a lower S/N than the B -band ( m AB (3 σ ) = 26 6 mag and 27 0 for 3' diameter aperture, respectively; . . Laigle et al. 2016) such that there is a small offset at 0 4 . /lessorsimilar z /lessorsimilar 0 6 for this filter set. . This is because higher weight is given to the B -band, together with the other optical bands, in the fits, which begins to probe the feature at z /greaterorsimilar 0 6 along with the . u -band. The z phot offset due to this feature in dusty galaxies can be larger if a filter probes this region and a few other bands surrounding the feature are available for fitting. The median redshift offset of the sample for runs without a 2175 ˚ A feature is z phot (w o 2175 ˚ ) / A -z phot (w / 2175 ˚ ) = A -0 03 . and this translates to an underestimate of the spectroscopic redshift, with z phot (w o 2175 ˚ ) / A -z spec /similarequal -0 03 . (not shown). This effect highlights that not properly accounting for this feature will result in a z -bias for dusty galaxies. In some photoz codes, a subtle z -bias can typically be corrected for by applying zeropoint offsets or template corrections in order to minimize model residuals at the spectroscopic redshift. This procedure is not performed in MAGPHYS+photo -z because it would impact the ability to constrain physical properties by effectively altering the shape of the observed SED. We note that the 2175 ˚ feature has very little influence on the resultA ing physical property constraints, due to the minimal role it plays in the total attenuation energy budget, but that a z -bias effect will directly translate to biases in all luminosity-dependent quantities.

Figure 9. Similar to Figure 2, but demonstrating the MAGPHYS+photo -z results for a randomly selected G10 galaxy when utilizing a subset of the available filters (colored curves) compared to the full filter set (black curve). The SEDs are shown in terms of flux instead of luminosity for easier comparison between the fits. The symbol sizes in the residual panel are varied for clarity. The fit using the FUV-IRAC2 bands (green curve) is able to constrain the redshift and stellar mass well, but does a poor job reproducing the other parameters. Conversely, the fit to the IRAC1-SPIRE500 bands provides a less precise redshift estimate and only provide constraints on the dust parameters. The IR-only fits often have multi-peak solutions for z phot and other parameters due to a z T -dust degeneracy. Using the full SED provides the tightest constraints on z phot , and therefore also on the constraints for the other luminosity-dependent physical properties.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-54fba13f-9f48-4361-b443-367431b89e1b.jpg)

For all previous analyses, we have assumed characteristics for the shape of the 2175 ˚ A feature based on the MW extinction curve. However, the assumption of a fixed central wavelength and FWHM may not be accurate for galaxy attenuation curves (e.g., Noll et al. 2009). From fixed-redshift runs of standard MAGPHYS , we find that the central wavelength of the absorption feature, based on intermediate band data, is very close to the MW value (Battisti et al. in prep.), suggesting that this central wavelength is a reasonable assumption. We also test the effect of reducing the width of the 2175 ˚ A feature in the code to 300 ˚ , A corresponding to the average value found by Noll et al. (2009) for spectroscopically observed z /similarequal 2 galaxies, and find that this has a small effect on the z phot results (typically | ∆ z phot ) | /lessorsimilar 0 01, which is below the scatter) and . does not lead to significant improvement in the quality of the fits (based on χ 2 ). We conclude that the MAGPHYS+photo -z fitting results are not overly sensitive to the characterization adopted for the 2175 ˚ A feature shape, especially when most general application will be on broadband data, but that accounting for additional absorption in this region is a required ingredient in the SED models to mitigate z -bias effects.

## 5.4. Comparison with LePhare

As a comparative test of MAGPHYS+photo -z , we examine the photoz values in the COSMOS2015 catalog that are computed using the LePhare code (Arnouts et al.

Figure 10. Difference between z phot values obtained for our COSMOS samples when the additional 2175 ˚ absorpA tion feature is not included in our models relative to when it is included. The z phot values for runs without the 2175 ˚ A feature are systematically lower at most redshifts, with a median offset of z phot (w o 2175 ˚ ) / A -z phot (w / 2175 ˚ ) = A -0 03. . The offset depends strongly on the number of filters that probe the 2175 ˚ A region, their filter width, and their sensitivity ( S/N ). These effects result in the variation of the z -bias as a function of redshift. When the feature is not accounted for in our models, we systematically underestimate the correct redshift.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-80b159e9-3e00-4c40-bdf2-ae14f7849c94.jpg)

2002; Ilbert et al. 2006) as described in Laigle et al. (2016). The Laigle et al. (2016) results are based on total flux values of all broad and intermediate-bands (3 ′′ + aperture correction) and these are the same values adopted in our analysis (Section 4.1). As a brief summary, LePhare uses a set of 33 galaxy templates that include emission lines together with three extinction/attenuation curves considered: 1) the starburst attenuation curve (Calzetti et al. 2000), 2) a modified version of the starburst curve including a 2175 ˚ A bump (Fitzpatrick &amp; Massa 1986), 3) and the Small Magellanic Cloud extinction curve (Prevot et al. 1984). An important aspect of LePhare that distinguishes it from MAGPHYS+photo -z is that it computes systematic offsets that are applied to the predicted magnitudes in order to minimize the residuals with the observations for the spectroscopic sample (Ilbert et al. 2006). These offsets have the same effect as changing the photometric zeropoint of individual bands. In MAGPHYS+photo -z we choose not to adopt a similar approach because it is equivalent to slightly altering the intrinsic shape of the observed SED and this impacts the derived physical properties.

For our comparison, we use two subsamples of the COSMOS2015 catalog: 1) galaxies in our main IR- detected sample that requires at least one band ≥ 24 µ m with S/N &gt; 3 and 2) galaxies without any IR detection (i.e., independent from the sample used in the previous analysis). Using a sample without the IR requirement enables a much larger sample of highz galaxies to be compared and will also span a wider range of galaxy properties. AGN are excluded in the IR sample using the methods described in Section 3.3, leaving 2,008 galaxies. We note that this is slightly larger than the previously used C15+SD sample because here we do not remove duplicates with the G10 sample. For the sample without IR detection, AGN are excluded using IRAC colors (Donley et al. 2012), radio (Seymour et al. 2008), and X-ray selection techniques. We also exclude sources with fewer than 8 bands detected at S/N &gt; 3 (removes &lt; 1% of the sample; median number of detected filters is 26). To reduce the total computational cost of this sample, we randomly select 3,000 galaxies from the total population at z &lt; 1 5 but use all galax-. ies in the sample at z ≥ 1 5. . These steps leave a final sample of 4,514 galaxies.

We compare the output of the two codes for the IRdetected sample in Figure 11, Left . Both codes show agreement in their photometric values and the correct redshift ( ∆ | z / | (1 + z spec ) &lt; 0 1) for 92.6% of the sam-. ple. We find that in 1.8% of cases MAGPHYS+photo -z has | ∆ z / | (1+ z spec ) &lt; 0 1 and . LePhare has | ∆ z / | (1+ z spec ) &gt; 0 1 . (i.e., MAGPHYS+photo -z performs better), 2.4% of cases where the opposite is true, and 3.1% of cases where both cases have | ∆ z / | (1 + z spec ) &gt; 0 1 (i.e., both . codes obtain incorrect redshift). A comparison of photoz metrics for each code are shown in Table 3 and are of comparable quality. There is a slight offset evident at z /greaterorsimilar 2 between MAGPHYS+photo -z and LePhare z phot values. This effect will be discussed further after comparing the sample without IR detections. The fraction of cases for which the z phot 1 σ confidence ranges are in agreement with z spec is 44% and 35% for MAGPHYS+photo -z and LePhare , respectively.

We compare the output of the two codes for the sample without an IR detection in Figure 11, Right . For the following discussion, we are excluding 21 galaxies for which no z phot is reported from LePhare . The codes show agreement ( ∆ | z / | (1 + z spec ) &lt; 0 1) in . their photometric values for 89.5% of the sample (black circles). We find that in 2.3% of cases MAGPHYS+photo -z produces redshifts with | ∆ z / | (1 + z spec ) &lt; 0 1 and . LePhare does not, 2.8% of cases where the opposite is true, and 5.4% of cases where both are below this accuracy. The larger disagreement in this sample by both codes is mostly due to these sources being fainter (lower S/N ) than the IR selected sample. The comparison of photoz metrics are

Figure 11. Comparison between the photometric redshifts of MAGPHYS+photo -z and LePhare for COSMOS2015 galaxies. ( Left: ) Results for the IR-detected sample (C15+SD catalog). Both codes rely on the same photometric data, however LePhare uses only the observed UV-NIR data in the COSMOS2015 catalog for fitting. Black circles indicate cases where both codes provide the correct redshift within | ∆ z / | (1 + z spec ) &lt; 0 1. . Colored circles indicate cases where one code or both codes fail to estimate the correct redshift and have | ∆ z / | (1 + z spec ) &gt; 0 1. . ( Right: ) Comparison for galaxies without an IR detection using the same photometric data (from NUV to IRAC ch4). There is a slight offset present in the values of z phot at z spec /greaterorsimilar 2. We believe this to be the result of photometric effects (explored in Appendix B). In both cases, MAGPHYS+photo -z performs very well with ∼ 95% agreement with LePhare ( ∼ 90% both codes agree correctly, ∼ 5% both agree incorrectly).

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-da779a9f-a95e-4a51-b48b-517bbae9d543.jpg)

shown in Table 3 and are similar between the codes. The fraction of cases for which the z phot 1 σ confidence ranges are in agreement with z spec is 41% and 43% for MAGPHYS+photo -z and LePhare , respectively. It is worth noting that despite imposing a non-zero prior for the 2175 ˚ bump strength, the resulting photoA z estimates for the non-IR sample show similar agreement as for the IR-detected sample. In general, LePhare obtains slightly better z phot metrics than MAGPHYS+photo -z because it implements zeropoint offsets (i.e., 'tunes' the data/models), it does not impose a minimum photometric uncertainty, and also includes emission lines.

Looking at both panels of Figure 11, there is a slight disagreement in z phot values at z /greaterorsimilar 2 between MAGPHYS+photo -z and LePhare . For the sample without IR detection, we find that MAGPHYS+photo -z has z -bias( z &gt; 2) = -0 019, . whereas LePhare has z -bias( z &gt; 2) = 0 009. . This indicates that MAGPHYS+photo -z is slightly underestimating the value of z phot for these samples at high redshifts compared to LePhare , which slightly overestimates the z phot . We note that the updated z phot values from Davidzon et al. (2017), which used LePhare in a manner optimized for z &gt; 2 5 . galaxies (see paper for details), show a lower offset for the higher redshift galaxies with a z -bias( z &gt; 2) = 0 001. . The MAGPHYS+photo -z offset is not particularly large, but we sought to investigate the factors that could lead to an offset. The results from our self-consistency tests (Section 5.1) would suggest that this offset is not a result of the methodology and instead may be attributed to either a shortcoming of our current models in representing the data or the result of a photometric zeropoint/measurement issues. One difference between MAGPHYS+photo -z and LePhare is the attenuation prescription. However, we found that adopting a fixed attenuation curve of the diffuse ISM ( ∝ λ -0 7 . ), which is similar in shape to the starburst attenuation curve used in LePhare , did not lead to noticeable change the to average values of z phot . A second difference between the codes is that LePhare modifies the zeropoint flux values to minimize χ 2 values based on calibration with the z spec sample and this is not performed in MAGPHYS . We indirectly explore the effect of differences in the photometric dataset in Appendix B where we use independent photometric catalogs from CANDELS for high redshift galaxies. Those results do

Table 3. Comparison of photoz metrics (defined in Section 4.1.1) between MAGPHYS+photo -z and LePhare .

|                   | IR-detected            | IR-detected   | Sample         |
|-------------------|------------------------|---------------|----------------|
| Code              | σ NMAD                 | η             | z -bias        |
| MAGPHYS+photo - z | 0.027                  | 0.033         | -0.010         |
| LePhare           | 0.022                  | 0.029         | -0.005         |
| Code              | No IR detection σ NMAD | η             | Sample z -bias |
| MAGPHYS+photo - z | 0.031                  | 0.055         | -0.010         |
| LePhare           | 0.018                  | 0.056         | -0.002         |

not show a significant z -bias at z &gt; 2 and indicates that the z phot offset may be attributed to small zeropoint changes and/or differences in methodology. In rare instances, the lack of emission lines in our models, but which are included in LePhare , could also lead to differences in the z phot estimates. We plan to revisit the issue of a possible z -bias in MAGPHYS+photo -z as it undergoes continued testing on a broader range of independent photometric datasets in the future. However, in its current state, it appears to perform well and achieves similar levels of accuracy as 'classic' photoz codes.

In addition to z phot , LePhare also estimates the stellar mass ( M ∗ ) of each galaxy using a library of synthetic spectra generated with the stellar population models of Bruzual &amp; Charlot (2003) and these are also included in the COSMOS2015 catalog (for details, see Laigle et al. 2016). The same stellar population models are also utilized in MAGPHYS , along with the same initial mass function (Chabrier 2003), and thus differences in the M ∗ between the codes (for galaxies at the same z phot ) should mainly be attributed to different treatments/assumptions for the SFH, metallicity, and/or dust attenuation. The M ∗ is generally the most reliable physical parameter constrained by SED modeling, typically varying by ∼ 0 3 dex or less (e.g., . Conroy 2013; Hunt et al. 2019). This is because the mass-to-light ratios in the optical-NIR regions (redward of V -band) are relatively stable across a wide range of SFHs and other assumptions (e.g., Bell &amp; de Jong 2001; Zibetti et al. 2009).

We compare the M ∗ inferred from MAGPHYS+photo -z and LePhare for the two COSMOS2015 subsamples in Figure 12 ( Top ). It can be seen that for the IRdetected sample, which is biased toward dustier galaxies, the inferred M ∗ from MAGPHYS+photo -z is systematically higher than LePhare , being most disparate at the highest masses ( /greaterorsimilar 10 10 M /circledot ). We examine the influence of the assumed dust attenuation by comparing the difference in M ∗ as a function of A V in Figure 12 ( Bottom ). There is a significant trend where larger differences occur for dustier galaxies (these also tend to be more massive), with the highest A V cases differing in M ∗ by up to a factor of two ( ∼ 0.3 dex). The change in M ∗ with increasing A V is primarily a consequence of significant levels of dust attenuation on the SEDs in the opticalNIR region for the dustiest galaxies, which is required through the assumption of energy balance. Without the constraints from the IR data, the dust attenuation for these sources is underestimated in LePhare . In fact, 53% of the IR-detected sample have E B ( -V ) = 0 ( A V = 0) for the best-fit Bruzual &amp; Charlot (2003) model in LePhare ( extinction parameter in COSMOS2015 catalog). An example of significant optical-NIR attenuation for a massive, dusty galaxy can be seen in Figure 2 by comparing the best-fit intrinsic and attenuated model SEDs in the upper panel. However, it is worth emphasizing again that the IR-detected sample is highly biased toward cases where codes only relying on UV-NIR data, such as LePhare , are prone to have issues. Indeed, when we examine the sample of galaxies without IR detection (typically less dusty galaxies), the M ∗ values are in much closer agreement. Looking at the difference in M ∗ as a function of A V for those cases, it can be seen that the agreement coincides with the low inferred values for A V in this sample. However, similar to before, the trend of large mass difference is seen for the small fraction of cases with large inferred A V . For reference, the 1 σ dispersion in the mass difference for the different A V bins in both samples are ∼ 30% ( ∼ 0.12 dex). These results suggest that the additional IR coverage provided in MAGPHYS+photo -z is very important for accurate stellar mass estimation of dusty galaxies.

## 6. CONCLUSION

We have developed an extension of the spectral modeling code MAGPHYS , called MAGPHYS+photo -z , that allows the estimation of galaxy redshift simultaneously with other physical properties and their uncertainties in a manner that incorporates the redshift uncertainty. The success of the code in estimating photometric redshifts and physical properties is demonstrated for galaxies at 0 4 . &lt; z &lt; 6 0 in the COSMOS field. . The main results of the paper are summarized below:

- · For IR-detected COSMOS galaxies, we achieve high photoz precision ( σ NMAD /lessorsimilar 0 04), high accu-. racy (i.e., minimal offset biases; median(∆ z/ (1 + z spec )) /lessorsimilar 0 02), and low catastrophic failure rates . ( η /similarequal 4%) over all redshifts. These results are comparable to those obtained with the LePhare code.

Figure 12. Comparison between the stellar mass ( M ∗ ) inferred from MAGPHYS+photo -z and LePhare for COSMOS2015 galaxies. Top: Direct stellar mass comparison for the IR-detected sample ( Left ) and the sample without any IR detection ( Right ). Black circles indicate cases where the z phot of both codes agree within | ∆ z phot | &lt; . 0 3. Red circles indicate cases where z phot disagree. The two codes show a sizable disagreement for the high-mass, IR-detected galaxies, which is related to the inferred amount of dust attenuation (see lower panels). In contrast, the non-IR sample show much closer agreement because of the lower levels of attenuation. Bottom: Difference in stellar mass as a function of the effective V -band dust attenuation ( A V ) for each sample. There is a significant trend where dustier galaxies have systematically higher stellar masses in MAGPHYS+photo -z relative to LePhare , with the highest A V cases differing by up to a factor of two ( ∼ 0.3 dex). This effect is primarily a consequence of inferring significant dust attenuation on the SED at optical-NIR wavelengths (e.g., compare intrinsic and attenuated SEDs in Figure 2).

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-8a26cfa2-697c-489b-b613-23acf8471ebe.jpg)

- · The derived physical properties of galaxies using MAGPHYS+photo -z are consistent with those derived from the fixed-redshift ( z spec ) using standard MAGPHYS .
- · We demonstrate a strong correlation between photometric redshift uncertainty and the uncertainty of other derived physical properties that is critical to account for in studies of galaxy evolution based on photoz 's.
- · The inclusion of a weak 2175 ˚ A absorption feature in the attenuation curve model is required to remove a subtle systematic z phot offset ( z phot -z spec /similarequal -0 03) that would otherwise be present for . our sample of IR-detected galaxies.
- · We compare stellar masses inferred from MAGPHYS+photo z and LePhare and find that for dusty star-forming galaxies (large A V ) the M ∗ can be underestimated by up to a factor of 2 ( ∼ 0.3 dex) in the latter, being most disparate at the highest stellar masses ( /greaterorsimilar 10 10 M /circledot ). This highlights an issue that can arise for dusty galaxies in codes attempting to estimate properties from rest-frame UV-NIR data alone.

MAGPHYS+photo -z is unique among existing codes in that it includes IR, sub-mm, and radio data when constraining z phot . This is particularly beneficial for dusty, highz galaxies that are often undetected at rest-frame UV-optical wavelengths. The main benefit to utilizing MAGPHYS+photo -z is that there is no need for users to run their catalogs through dedicated photoz codes prior to determination of galaxy physical properties. The selfconsistent photoz and SED modeling capability of this code provides users with a reliable and easy method for interpreting large photometric datasets to study galaxy evolution.

## ACKNOWLEDGMENTS

-The authors thank the anonymous referee whose suggestions helped to clarify and improve the content of this work. EdC gratefully acknowledges the Australian Research Council as the recipient of a Future Fellowship (project FT150100079). Parts of this research were supported by the Australian Research Council Centre of Excellence for All Sky Astrophysics in 3 Dimensions (ASTRO 3D), through project number CE170100013. AJB thanks C. Laigle for correspondence regarding COSMOS2015 catalog usage. AJB also thanks S. Charlot, I. Davidzon, and O. Ilbert for comments that improved the manuscript. AJB is also thankful for attending ASTRO 3D writing retreats that provided a helpful environment to complete portions of this manuscript. We thank the invaluable labor of the maintenance and clerical staff at our institutions, whose contributions make our scientific discoveries a reality. Based on data products from observations made with ESO Telescopes at the La Silla Paranal Observatory under ESO programme ID 179.A2005 and on data products produced by TERAPIX and the Cambridge Astronomy Survey Unit on behalf of the UltraVISTA consortium.

## REFERENCES

Andrews, S. K., Driver, S. P., Davies, L. J. M., et al. 2017, MNRAS, 464, 1569 Arnouts, S., Moscardini, L., Vanzella, E., et al. 2002, MNRAS, 329, 355 Baldry, I. K., Robotham, A. S. G., Hill, D. T., et al. 2010, MNRAS, 404, 86 Battisti, A. J., Calzetti, D., &amp; Chary, R.-R. 2017, ApJ, 851, 90 Bell, E. F., &amp; de Jong, R. S. 2001, ApJ, 550, 212 Ben´ ıtez, N. 2000, ApJ, 536, 571 Bertin, E., &amp; Arnouts, S. 1996, A&amp;AS, 117, 393 Blain, A. W., &amp; Longair, M. S. 1993, MNRAS, 264, 509 Bolzonella, M., Miralles, J.-M., &amp; Pell´, R. 2000, A&amp;A, o 363, 476 Boquien, M., Burgarella, D., Roehlly, Y., et al. 2019, A&amp;A, 622, A103

Brammer, G. B., van Dokkum, P. G., &amp; Coppi, P. 2008,

ApJ, 686, 1503 Brinchmann, J., Charlot, S., White, S. D. M., et al. 2004, MNRAS, 351, 1151 Brinchmann, J., Inami, H., Bacon, R., et al. 2017, A&amp;A, 608, A3 Brusa, M., Zamorani, G., Comastri, A., et al. 2007, ApJS, 172, 353 Brusa, M., Civano, F., Comastri, A., et al. 2010, ApJ, 716, 348 Bruzual, G., &amp; Charlot, S. 2003, MNRAS, 344, 1000 Buat, V., Noll, S., Burgarella, D., et al. 2012, A&amp;A, 545, A141 Calzetti, D. 2001, PASP, 113, 1449 Calzetti, D., Armus, L., Bohlin, R. C., et al. 2000, ApJ, 533, 682

| Calzetti, D., Kinney, A. L., & Storchi-Bergmann, T. 1994, ApJ, 429, 582                                    |
|------------------------------------------------------------------------------------------------------------|
| Capak, P., Aussel, H., Ajiki, M., et al. 2007, ApJS, 172, 99                                               |
| Cappellari, M. 2016, ARA&A, 54, 597                                                                        |
| Cappelluti, N., Brusa, M., Hasinger, G., et al. 2009, A&A, 497, 635                                        |
| Chabrier, G. 2003, PASP, 115, 763                                                                          |
| Chang, Y.-Y., Le Floc'h, E., Juneau, S., et al. 2017, ApJS, 233, 19                                        |
| Charlot, S., & Fall, S. M. 2000, ApJ, 539, 718                                                             |
| Chevallard, J., & Charlot, S. 2016, MNRAS, 462, 1415                                                       |
| Civano, F., Elvis, M., Brusa, M., et al. 2012, ApJS, 201, 30                                               |
| Civano, F., Marchesi, S., Comastri, A., et al. 2016, ApJ, 819, 62                                          |
| Condon, J. J., & Matthews, A. M. 2018, PASP, 130, 073001                                                   |
| Conroy, C. 2013, ARA&A, 51, 393                                                                            |
| da Cunha, E., Charlot, S., & Elbaz, D. 2008, MNRAS, 388, 1595                                              |
| da Cunha, E., Walter, F., Smail, I. R., et al. 2015, ApJ, 806, 110                                         |
| Dahlen, T., Mobasher, B., Faber, S. M., et al. 2013, ApJ, 775, 93                                          |
| Davidzon, I., Ilbert, O., Laigle, C., et al. 2017, A&A, 605, A70                                           |
| Davies, L. J. M., Driver, S. P., Robotham, A. S. G., et al. 2015, MNRAS, 447, 1014                         |
| Donley, J. L., Koekemoer, A. M., Brusa, M., et al. 2012, ApJ, 748, 142                                     |
| Draine, B. T. 2003, ARA&A, 41, 241 Driver, S. P., Hill, D. T., Kelvin, L. S., et al. 2011, MNRAS, 413, 971 |
| Dunlop, J. S., Cirasuolo, M., & McLure, R. J. 2007, MNRAS, 376, 1054                                       |
| Elvis, M., Civano, F., Vignali, C., et al. 2009, ApJS, 184, 158                                            |
| Fitzpatrick, E. L. 1999, PASP, 111, 63                                                                     |
| Fitzpatrick, E. L., & Massa, D. 1986, ApJ, 307, 286 -. 2007, ApJ, 663, 320                                 |
| Galametz, A., Grazian, A., Fontana, A., et al. 2013, ApJS, 206, 10                                         |
| Gordon, K. D., Calzetti, D., & Witt, A. N. 1997, ApJ, 487, 625                                             |
| Grogin, N. A., Kocevski, D. D., Faber, S. M., et al.                                                       |
| 2011, ApJS, 197, 35                                                                                        |
| Guo, Y., Ferguson, H. C., Giavalisco, M., et al. 2013, ApJS, 207, 24                                       |
| Han, Y., & Han, Z. 2014, ApJS, 215, 2                                                                      |

| Hasinger, G., Cappelluti, N., Brunner, H., et al. 2007, ApJS, 172, 29                                 |
|-------------------------------------------------------------------------------------------------------|
| Hoaglin, D. C., Mosteller, F., & Tukey, J. W. 1983, Understanding Robust and Exploratory Data Anlysis |
| Hogg, D. W. 1999, ArXiv Astrophysics e-prints, astro-ph/9905116                                       |
| Hopkins, A. M., Driver, S. P., Brough, S., et al. 2013, MNRAS, 430, 2047                              |
| Hunt, L. K., De Looze, I., Boquien, M., et al. 2019, A&A, 621, A51                                    |
| Ilbert, O., Arnouts, S., McCracken, H. J., et al. 2006, A&A, 457, 841                                 |
| Ilbert, O., Capak, P., Salvato, M., et al. 2009, ApJ, 690, 1236                                       |
| Inoue, A. K., Shimizu, I., Iwata, I., & Tanaka, M. 2014, MNRAS, 442, 1805                             |
| Jin, S., Daddi, E., Liu, D., et al. 2018, ApJ, 864, 56                                                |
| Johnston, R., Vaccari, M., Jarvis, M., et al. 2015, MNRAS, 453, 2540                                  |
| Kirkpatrick, A., Pope, A., Charmandaris, V., et al. 2013, ApJ, 763, 123                               |
| Kriek, M., & Conroy, C. 2013, ApJL, 775, L16                                                          |
| Kriek, M., van Dokkum, P. G., Labb´, e I., et al. 2009, ApJ, 700, 221                                 |
| Kriek, M., Shapley, A. E., Reddy, N. A., et al. 2015, ApJS, 218, 15                                   |
| Laigle, C., McCracken, H. J., Ilbert, O., et al. 2016, ApJS, 224, 24                                  |
| Le Borgne, D., & Rocca-Volmerange, B. 2002, A&A, 386, 446                                             |
| Leja, J., Johnson, B. D., Conroy, C., van Dokkum, P. G., &                                            |
| Byler, N. 2017, ApJ, 837, 170 Lilly, S. J., Le F`vre, e O., Renzini, A., et al. 2007, ApJS,           |
| Lilly, S. J., Le Brun, V., Maier, C., et al. 2009, ApJS, 184, 218                                     |
| Liu, D., Daddi, E., Dickinson, M., et al. 2018, ApJ, 853, 172 Madau, P. 1995, ApJ, 441, 18            |
| Marchesi, S., Civano, F., Elvis, M., et al. 2016, ApJ, 817, 34                                        |
| McLure, R. J., Pentericci, L., Cimatti, A., et al. 2018, MNRAS, 479, 25                               |
| Nayyeri, H., Hemmati, S., Mobasher, B., et al. 2017, ApJS, 228, 7                                     |
| Noll, S., Pierini, D., Cimatti, A., et al. 2009, A&A, 499, 69                                         |
| Pacifici, C., da Cunha, E., Charlot, S., et al. 2015, MNRAS, 447, 786                                 |
| Pentericci, L., McLure, R. J., Garilli, B., et al. 2018, A&A, 616, A174                               |

| Prevot, M. L., Lequeux, J., Maurice, E., Prevot, L., & Rocca-Volmerange, B. 1984, A&A, 132, 389                                |
|--------------------------------------------------------------------------------------------------------------------------------|
| Reddy, N. A., Kriek, M., Shapley, A. E., et al. 2015, ApJ, 806, 259                                                            |
| Robotham, A., Driver, S. P., Norberg, P., et al. 2010, PASA, 27, 76                                                            |
| Rowan-Robinson, M., Babbedge, T., Oliver, S., et al. 2008, MNRAS, 386, 697                                                     |
| Salim, S., Boquien, M., & Lee, J. C. 2018, ApJ, 859, 11                                                                        |
| Salmon, B., Papovich, C., Long, J., et al. 2016, ApJ, 827, 20                                                                  |
| Salvato, M., Ilbert, O., & Hoyle, B. 2018, Nature                                                                              |
| Astronomy, arXiv:1805.12574 Schlegel, D. J., Finkbeiner, D. P., & Davis, M. 1998, ApJ,                                         |
| Scoville, N., Faisst, A., Capak, P., et al. 2015, ApJ, 800, 108 Scoville, N., Aussel, H., Brusa, M., et al. 2007, ApJS, 172, 1 |
| Scoville, N., Sheth, K., Aussel, H., et al. 2016, ApJ, 820, 83                                                                 |
| Seon, K.-I., & Draine, B. T. 2016, ApJ, 833, 201                                                                               |
| Seymour, N., Dwelly, T., Moss, D., et al. 2008, MNRAS, 386, 1695                                                               |
| Smith, D. J. B., & Hayward, C. C. 2018, MNRAS, 476,                                                                            |

- Speagle, J. S., Steinhardt, C. L., Capak, P. L., &amp; Silverman, J. D. 2014, ApJS, 214, 15
- Stefanon, M., Yan, H., Mobasher, B., et al. 2017, ApJS,
- 229, 32 Tacconi, L. J., Genzel, R., Saintonge, A., et al. 2018, ApJ, 853, 179 Tasca, L. A. M., Le F`vre, O., Ribeiro, B., et al. 2017, e A&amp;A, 600, A110 Tremonti, C. A., Heckman, T. M., Kauffmann, G., et al. 2004, ApJ, 613, 898 Walcher, J., Groves, B., Budav´ri, T., &amp; Dale, D. 2011, a Ap&amp;SS, 331, 1 Wild, V., Charlot, S., Brinchmann, J., et al. 2011, MNRAS, 417, 1760 Witt, A. N., &amp; Gordon, K. D. 2000, ApJ, 528, 799 Wright, A. H., Robotham, A. S. G., Bourne, N., et al. 2016, MNRAS, 460, 765 Yun, M. S., Reddy, N. A., &amp; Condon, J. J. 2001, ApJ, 554, 803 Zavala, J. A., Aretxaga, I., &amp; Hughes, D. H. 2014, MNRAS, 443, 2384 Zibetti, S., Charlot, S., &amp; Rix, H.-W. 2009, MNRAS, 400, 1181

Figure 13. Comparison between the photometric and spectroscopic redshifts for AGN in the COSMOS field using MAGPHYS+photo -z . The diagnostic used to identify the AGN is indicated as a solid black circle, open red circle, and open purple star symbols for IR, Radio, and X-ray methods, respectively. Note, some cases are identified by multiple methods. Despite lacking AGN models, the code still performs reasonably well in estimating z phot for a majority of cases. The majority of catastrophic failures coincide with IR AGN with high χ 2 values, indicating the AGN is significantly affecting the SED and not being fit well.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-2fc70d53-9062-48ff-8042-0f75853bf672.jpg)

## APPENDIX

## A. RELIABILITY OF PHOTOz FOR AGN

Here we briefly examine the photoz results for the AGN sources in our COSMOS samples using MAGPHYS+photo -z . These include 179 and 117 AGN in the G10 and C15+SD samples, respectively. We distinguish this sample as IR, radio, and/or X-ray AGN, based on the diagnostic utilized to identify them. For G10, the breakdown is 126, 42, and 13, respectively. For C15+SD, the breakdown is 45, 64, and 26, respectively. Note that sources can be identified with multiple diagnostics (there are 2 and 9 multiply diagnosed AGN in the G10 and C15+SD samples, respectively). It is also worth stating that these selections are incomplete due to different depths for the various bands utilized.

As a reminder, current versions of MAGPHYS do not include AGN models, although this is planned for an upcoming release, and therefore we expect the code to perform worse for these sources. We do not explore the quality of physical property estimates for AGN sources because this would require a comparison to fits that include AGN models and is beyond the scope of this paper. The z phot results are shown in Figure 13 along with the corresponding quality metrics for each sample ( σ NMAD , η , and z -bias). Different symbols are used for the 3 AGN classes. These results indicate that despite the lack of AGN models, the z phot estimates for AGN are still reasonably well determined in most cases, with only a slightly higher σ NMAD than for the normal galaxy sample. However, the instance rate of catastrophic failures is noticeably larger, being almost 20% for the C15+SD sample.

The AGN class that appears to be most susceptible to catastrophic failure are those identified using IR diagnostics. The IR AGN make up 88% and 91% of the catastrophic failures for the G10 and C15+SD samples, respectively. This is not surprising since our SED fits include the IR regime but not the radio (for these runs) or X-ray. However, a

significant fraction of the IR AGN still obtain reasonable z phot estimates, with 83% and 49% of these cases having ∆ z/ (1 + z spec ) &lt; 0 15 for the G10 and C15+SD samples, respectively. . The catastrophic failure cases are primarily instances where the AGN is dominating the IR SED and, as will be discussed next, this can be gauged by the χ 2 values of the best-fit SED. In contrast, the radio AGN make up only 8.3% and 4.5% of the catastrophic failures for the G10 and C15+SD samples, respectively, and the X-ray AGN are only 4.2% and 9.1%, respectively. Over 90% of the radio and X-ray AGN have ∆ z/ (1 + z spec ) &lt; 0 15 for both samples. .

As expected, the MAGPHYS+photo -z fits to the AGN sources also have considerably higher χ 2 values on average than those for the normal galaxies. We find that 30% and 42% of the G10 and C15+SD AGN sample, respectively, lie above the χ 2 &gt; χ ¯ 2 + 4 σ χ ( 2 ) thresholds discussed in Section 4.1. We recommend users adopt a χ 2 threshold cut to galaxy samples to reject possible AGN, stellar, or other sources that are not accounted for in the current models. The distribution of χ 2 values will change from sample to sample, depending on the photometric quality and which regions of the SED are sampled. Therefore, it is best to make cuts based on the χ 2 distribution for each sample instead of using a specific χ 2 value across different samples. For example, imposing the cut χ 2 &gt; χ ¯ 2 + 4 σ χ ( 2 ), discussed in Section 4.1, would remove 71% and 91% of the AGN sources experiencing z phot catastrophic failures in the G10 and C15+SD samples, respectively. The sources with the highest χ 2 values correspond to cases with a dominant influence of the AGN on their IR SED and therefore they are more poorly constrained in MAGPHYS+photo -z . Unfortunately, as the number of available bands being fit decreases, it becomes more difficult to identify AGN sources for exclusion using the χ 2 metric.

## B. MAGPHYS+PHOTOz RESULTS USING CANDELS PHOTOMETRY

In Section 5.4, we find evidence the z phot values for COSMOS2015 that galaxies at z /greaterorsimilar 2 are slightly underestimated relative to z spec . To examine if this is due to a potential issues with MAGPHYS+photo -z , we explore if similar offsets are found for galaxies with independent photometry from CANDELS (Grogin et al. 2011; Koekemoer et al. 2011). We utilize the CANDELS photometric catalogs that are based on using the Sextractor version 2.8.6 (Bertin &amp; Arnouts 1996) in dual mode with the WFC3 F160W as the detection band (for details see Nayyeri et al. 2017).

First, we use the catalog of the COSMOS field from Nayyeri et al. (2017), which spans filters from u to Spitzer /IRAC ch4, and cross-match those objects with the COSMOS master spectroscopic catalog (curated by M. Salvato). The photometric data include the same filters as the G10 and COSMOS2015 catalogs, as shown in Table 1 (up to IRAC ch4), with additional filters from HST /ACS, HST /WFC3, and Mayall/NEWFIRM. It is important to note that for this analysis the longest wavelength being utilized is IRAC ch4 (as is the case for the non-IR galaxies Section 5.4). These cross-matched catalogs provide us with a parent sample of 1,836 CANDELS galaxies with spectroscopic redshifts at z spec &gt; 0 4. . We remove 35 galaxies that have IRAC colors consistent with AGN using the color selections of Donley et al. (2012), leaving a sample of 1,801 galaxies for analysis. The resulting photometric redshifts are shown in Figure 14 and are in excellent agreement with the spectroscopic redshift, with σ NMAD = 0 027, . η = 4 8%, and . z -bias = -0 009. These results are similar even if we adopt only the same filter set as COSMOS2015 for the CANDELS data, for . which we find σ NMAD = 0 029, . η = 4 9%, and . z -bias = -0 010. The redshift bias of the CANDELS data is noticeably . lower at higher redshifts, with z -bias( z &gt; 2) = -0 003, in contrast to what is found when using the COSMOS2015 . catalog ( z -bias( z &gt; 2) = -0 019). We attribute these changes to possible differences in adopted zeropoint magnitudes . and/or methodology for the photometry between the datasets. Indeed, when we examine overlapping spectroscopic sources between the CANDELS and COSMOS2015 catalogs ( N = 741), we find that the photometry can vary by 10 -20% in most bands. However, the flux in the shortest wavelength bands ( u , IA 427, B , etc.) bands are systematically higher ( ∼ 10%) relative to longer wavelength data in the COSMOS2015 catalog when compared to the CANDELS data. This situation is consistent with the slightly lower estimates for z phot (this effect is equivalent to less IGM absorption) when using the COSMOS2015 photometry.

As a separate independent check, we also tested MAGPHYS+photo -z on other CANDELS fields. We utilize the photometric catalogs available for the GOODS-S (Guo et al. 2013), UDS (Galametz et al. 2013), and EGS (Stefanon et al. 2017) fields, together with the spectroscopic redshifts of these fields from the MOSDEF (Kriek et al. 2015), VANDELS (McLure et al. 2018; Pentericci et al. 2018), and VUDS (Tasca et al. 2017) surveys. We only consider galaxies with 'robust' spectroscopic redshifts (reliability ≥ 95%) which are taken to be objects with Z QUAL ≥ 5 in MOSDEF, zflg =3 or 4 in VANDELS, and zflag =3 or 4 in VUDS. Duplicate cases are removed, with a preference towards higher quality cases. For galaxies at z spec &gt; 0 4, . we obtain 370 objects in GOODS-S (51 from MOSFIRE, 185 from VANDELS, 142 from VUDS; 8 duplicates), 264 objects in UDS (30 from MOSFIRE, 235 from VANDELS; 1 duplicate), 433 ob-

Figure 14. Left: Comparison between the photometric and spectroscopic redshifts for CANDELS-COSMOS galaxies using MAGPHYS+photo -z . Labels are the same as in Figure 3. No significant z -bias is found at z &gt; 2 using this dataset in contrast to the slight bias found for the non-IR COSMOS2015 sources. Right: Comparison between the photometric and spectroscopic redshifts using CANDELS data in the GOODS-S, UDS, and EGS fields. The agreement is again quite good with minimal z -bias. These results highlight that photometric differences (either through zeropoints or methodology) can introduce small systematic offsets in the z phot estimates.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00771v1-figure-fbddf0bb-9ec9-4151-9210-f397fe6ecfb9.jpg)

jects in EGS (451 from MOSFIRE; 18 duplicates). The resulting photometric redshifts are shown in Figure 14 and are also in excellent agreement with the spectroscopic redshift, with σ NMAD = 0 045, . η = 5 2%, and . z -bias = 0 006 . ( z -bias( z &gt; 2) = 0 004). .

From these results, we conclude that the z phot values found are subject to change slightly as a result of adopted photometric zeropoints or methodologies and also with the filters that are utilized. It is also important to mention again that intermediate-band data may also impact the accuracy of some sources due to the lack of emission lines in our models. However, the changes in z -bias between all samples examined appear relatively small and should not significantly affect the resulting physical properties derived with MAGPHYS+photo -z .
A. J. Battisti E. da Cunha K. Grasha M. Salvato E. Daddi L. Davies S. Jin D. Liu E. Schinnerer M. Vaccari
MAGPHYS+photo-z: Constraining the Physical Properties of Galaxies with Unknown Redshifts
We present an enhanced version of the multiwavelength spectral modeling code
MAGPHYS that allows the estimation of galaxy photometric redshift and physical
properties (e.g., stellar mass, star formation rate, dust attenuation)
simultaneously, together with robust characterization of their uncertainties.
The self-consistent modeling over ultraviolet to radio wavelengths in
MAGPHYS+photo-z is unique compared to standard photometric redshift codes. The
broader wavelength consideration is particularly useful for breaking certain
degeneracies in color vs. redshift for dusty galaxies with limited
observer-frame ultraviolet and optical data (or upper limits). We demonstrate
the success of the code in estimating redshifts and physical properties for
over 4,000 infrared-detected galaxies at 0.4<z<6.0 in the COSMOS field with
robust spectroscopic redshifts. We achieve high photo-z precision
($\sigma_{\Delta z/(1+z_{spec})}\lesssim0.04$), high accuracy (i.e., minimal
offset biases; median$(\Delta z/(1+z_{spec}))\lesssim0.02$), and low
catastrophic failure rates ($\eta\simeq4\%$) over all redshifts. Interestingly,
we find that a weak 2175A absorption feature in the attenuation curve models is
required to remove a subtle systematic photo-z offset
($z_{phot}-z_{spec}\simeq-0.03$) that occurs when this feature is not included.
As expected, the accuracy of derived physical properties in MAGPHYS+photo-z
decreases strongly as redshift uncertainty increases. The all-in-one treatment
of uncertainties afforded with this code is beneficial for accurately
interpreting physical properties of galaxies in large photometric datasets.
Finally, we emphasize that MAGPHYS+photo-z is not intended to replace existing
photo-z codes, but rather offer flexibility to robustly interpret physical
properties when spectroscopic redshifts are unavailable. The MAGPHYS+photo-z
code is publicly available online.