Quick viewing(Text Mode)

Arxiv:0909.0747V1 [Astro-Ph.EP] 3 Sep 2009 Ipiiyo Igeprmtrmdl H Eodrao I Reason Second the That Model

Arxiv:0909.0747V1 [Astro-Ph.EP] 3 Sep 2009 Ipiiyo Igeprmtrmdl H Eodrao I Reason Second the That Model

arXiv:0909.0747v1 [astro-ph.EP] 3 Sep 2009 ipiiyo igeprmtrmdl h eodrao i reason second The that model. single-parameter a of simplicity r fitdb orltdnie h hr esni httr that is reason third The they . if correlated even observations by afflicted single-event are of most Instea the com- observations. make by transit must improved multiple be from cannot results accuracy bining the such, as and event, h tr oe fatastlgtcremyhv many have the may parameter, curve single a light on transit mainly time a focus midtransit of we fro model i but received which A parameters, light star, the parent in star. its diminution of the slight disk the the trans of from front a evident in During passes planet transits. a exoplanetary of photometry series impractical. analyses certain makes This points). ehd scmuainlyitnie ihtime-complexi with traditi O intensive, the computationally of is unde generalization methods are esti Straightforward that errors parameter parameter estimated. give and inaccurate Traditional often are that correlations 1994). mates Beran ignore 1993, that Lombard methods challengin & noise more Koen is the e.g., ex- problem (see, when time—the noise However, in the correlations when hibits 2007). particularly well-understood—and al. not et rela- is Press is 20 2003, Robinson estimation & Gould Bevington parameter e.g., (see, of straightforward tively problem the uncorrelated, poten inhibits discoveries. errors important the d Overestimating between re- sets. contradictions new data apparent in ferent over confidence confusion unjustified or Under to sults, detectability. leads of errors edge in the the most timating on the often where are frontier, effects the research esting of the estima understanding at parameter thorough especially for tion, a methods gain appropriate param develop to and those important noise in is parameters uncertainties It the the ters. of for values estimates accurate reliable determine and and data series lcrncades atramteu [email protected] [email protected]; address: Electronic ( rpittpstuigL using typeset Preprint u pcfi ocr nti ae steaayi ftime- of analysis the is paper this in concern specific Our hnteerr ntedt r eludrto and understood well are data the in errors the When time- to model parametric a fit to wishes one Frequently A N CPE O ULCTO IN PUBLICATION FOR CCEPTED t 2 c ntewrtcss(where cases worst the in ) sauiu ic fifrainrgrigec transit each regarding information of piece unique a is ujc headings: Subject accur more uncertainties. gives their t here of to presented method residual-pe algorithm the the our and assumptions, compare method We time-averaging the time. literature, l midtransit the the photom estimating computing time-series to simulated on using based tested and estimation illustrated parameter for algorithm os.Teniei ersne yasmo w ttoayGau a varying stationary density two spectral of power sum a a has by that another represented and is time, noise The noise. ecnie h rbe ffitn aaercmdlt time- to model parametric a fitting of problem the consider We AAEE SIAINFO IESRE AAWT CORRELATE WITH DATA TIME-SERIES FROM ESTIMATION PARAMETER t AEE-AE EHDADISAPIAINT RNI LIGHT TRANSIT TO APPLICATION ITS AND -BASED METHOD A c o he esn.Tefis esni the is reason first The reasons. three for , A T E tl mltajv 08/22/09 v. emulateapj style X 1. INTRODUCTION ehd:saitcl—tcnqe:pooerc—sas pl stars: — photometric techniques: — statistical methods: T HE eateto hsc,adKviIsiuefrAstrophysic for Institute Kavli and , of Department A N STROPHYSICAL stenme fdata of number the is ascuet nttt fTcnlg,Cmrde A0213 MA Cambridge, Technology, of Institute Massachusetts cetdfrpbiaini h srpyia Journal Astrophysical The in publication for Accepted J OSHUA J OURNAL .C A. one d tially RE AND ARTER onal ABSTRACT ter- an- 03, es- if- it, m e- ty r- g s s - - tyo xpaeaytast,wt atclrattention particular with transits, exoplanetary of etry mtto ehd o os rcse htoe our obey that processes noise For method. rmutation sucreae,adteohro hc a oe spectral power a has which 1 sta- of as other varying two density the of and wh superposition uncorrelated, one the is which processes: as noise in Gaussian described (time-invariant) situations well tionary to is The applicable noise is methods. the advocated here a previously advocated two noise, method those time-correlated to of it presence compare the in estimation eter 2002). al. et (Jenkins t residuals the “residual-permutation preserves the the that of analysis and ordering bootstrap 2006) of variant al. a et method, the (Pont versi data time-binned are a the in of schemes scatter the correlati computing 2007, these by of al. assessed effects Among are the et which Winn in 2006; method, al. 2008). “time-averaging” et Southworth Gillon (s light 2006, algorithms 2009; transit al. estimation et of parameter Bakos analysis their e.g., co in the for errors account in to related attempted factor have practitioners limiting Many curves. a (“ noise is time-correlated that noise”) recognized widely been has it (2005)]. (2005) al. Murray tim et & transit Agol [Holman of perturbations gravitational a to planets in due additional anomalies discovering seeking of by satellites a offers timing sit oescnb nesoda opeetr oor1 our noise to ARMA complementary The as understood 1976). be Jenkins & can Box models pro- e.g., (ARMA) (see, average cesses moving autoregressive of framework rvttn ois e,eg,Kpig(2009). Kipping e.g., the see, bodies; on gravitating based is It method ad- transform. our wavelet taking explain, discrete by will the problem we of estimation vantage As parameter the (2000). accelerates al. (1997), et Timmer & Timmer Konig dis- (1993), and been Lombard has & context Koen by astronomical cussed an in estimati models are cor- Parameter ARMA long-range they with processes). to and (“long-memory” correlatio opposed relations domain, short-range as do- modeling processes) time for (“short-memory” the the suited in to naturally specified most opposed are as models ARMA main that in model, J OSHUA 1 t eut o itasttmsadturestimates truer and times midtransit for results ate nti ae epeeta lentv ehdfrparam- for method alternative an present we paper this In (2006), Queloz & Zucker, Pont, of work the with Beginning oetaiinlapoc otm-orltdniei the is noise time-correlated to approach traditional more A h rni uaini loepce ovr ntepresence the in vary to expected also is duration transit The 1 s klho nawvltbss h ehdis method The basis. wavelet a in ikelihood oohrmtosta aebe sdi the in used been have that methods other wo / sa rcse:oeta sucreae in uncorrelated is that one processes: ssian f .W N. γ eisdt htaeaflce ycorrelated by afflicted are that data series epeeta cuaeadfs [ fast and accurate an present We . n pc Research, Space and s INN 1 ntr systems anetary / 9 f γ . ERRORS: D CURVES O ( N )] fadditional of / ime ons red ich ee, nd on on f ns es or r- γ ” , 2 fact that a the of a 1/ f γ noise process is in which case there is only one error parameter, σ, specifying nearly diagonal in a wavelet basis. As long as the actual noise the width of the distribution. is reasonably well described by such a power law, our method If the noise is correlated then it is characterized by a joint is attractive for its simplicity, computational speed, and ease distribution that is generally a function of all the of implementation, in addition to its grounding in the recent times of observation. We assume that the function is a multi- literature on processing. variate Gaussian function, in which case the noise process is The use of the in is widespread, entirely characterized by the especially for the restoration, compression, and denoising of Σ(ti,t j)= ǫ(ti)ǫ(t j) . (4) images (see, e.g., Mallat 1999). Parameter estimation using h i wavelets has been considered but usually for the purpose of Here, the quantity ǫ is the of the function ǫ estimating noise parameters (Wornell 1996). An application over an infinite numberh i of independent realizations. We fur- of wavelets to the problem of linear regression with correlated ther assume that the covariance depends only on the differ- noise was given by Fadili & Bullmore (2002). What is new in ence in time between two samples, and not on the absolute this work is the extension to an arbitary nonlinear model, and time of either sample. In this case, the noise source is said to the application to transit light curves. be stationary and is described entirely by its autocovariance This paper is organized as follows. In § 2, we review the R(τ) (Bracewell 1965): problem of estimating model parameters from data corrupted R(τ) ǫ(t)ǫ(t + τ) . (5) by noise, and we review some relevant noise models. In § 3 ≡ h i we present the wavelet method and those aspects of wavelet The parameter estimation problem is often cast in terms of theory that are needed to understand the method. In § 4, finding the set of parameters pˆk that maximize a likelihood we test the method using simulated transit light curves, and function. For the case of Gaussian uncorrelated noise the compare the results to those obtained using the methods men- likelihood function is tioned previously. In § 5 we summarize the method and the N results of our tests, and suggest some possible applications 1 r2 = exp − i , (6) and extensions of this work. L √2 ˆ2 2σˆ2 i=1 πσ   2. PARAMETER ESTIMATION WITH “COLORFUL” NOISE Y where ri is the residual defined as yi − f (ti; ~p), and σˆ is an es- Consider an experiment in which samples of an observable timate of the single noise parameter σ. Maximizing the like- yi are recorded at a sequence of times ti : i =1,...,N . Inthe 2 { } lihood is equivalent to minimizing the χ statistic context of a transit light curve, yi is the relative brightness of L N 2 the host star. We assume that the times ti are known with neg- ri ligible error. We further assume that in the absence of noise, χ2 = . (7) σˆ the samples y would be given by a deterministic function, i i X  ˆ y(ti)= f (ti; p1,..., pK)= f (ti; ~p), (nonoise) (1) In transit photometry, the estimator σ of the noise parame- ter σ is usually not taken to be the calculated noise based on where ~p = p1,..., pK is a set of K parameters that spec- { } expected sources such as . This is because the ac- ify the function f . For an idealized transit light curve, those tual amplitude of the noise is often greater than the calculated parameters may be the fractional loss of light δ, the total du- value due to noise sources that are unknown or at least ill- ration T, and ingress or egress duration τ, and the midtransit quantified. Instead, σˆ is often taken to be the standard devia- time tc, in the notation of Carter et al. (2008). More realis- tion of the data obtained when the transit was not occurring, tic functions have been given by Mandel & Agol (2002) and or the value for which χ2 = N for the best-fitting (minimum- Giménez (2007). dof 2) model. These estimates work well when the noise process We further suppose that a stochastic noise process (t) has χ ǫ is Gaussian, stationary, and uncorrelated. For the case of cor- been added to the data, giving related noise, Eqn. (7) is replaced by (Gould 2003) + y(ti)= f (ti; ~p) ǫ(ti). (withnoise) (2) N N 2 Σˆ −1 As a stochastic function, ~ǫ = ǫ(t1),...ǫ(tN) is characterized χ = ri( )i jr j. (8) by its joint distribution function{ (~ǫ;~q), which} in turn de- i=1 j=1 pends on some parameters ~q andD possibly also the times of XX ˆ 2 observation. The goal of parameter estimation is to use the The case of uncorrelated noise corresponds to Σi j = σˆ δi j. data y(ti) to calculate credible intervals for the parameters ~p, It is at this point where various methods for modeling cor- ˆ ˆ Σˆ often reported as best estimates pk and error bars σpk with related noise begin to diverge. One approach is to estimate some quantified degree of confidence. The estimate of ~p and from the sample autocovariance Rˆ(τ) of the , just as the associated errors depend crucially on how one models the σˆ can be estimated from the standard deviation of the resid- noise and how well one can estimate the relevant noise pa- uals in the case of uncorrelated noise. However, the calcu- rameters ~q. lation of χ2 has a worst-case time-complexity of O(N2) and In some cases one expects and observes the noise to be un- iterative parameter estimation techniques can be prohibitively correlated. For example, the dominant noise source may be slow. One might ameliorate the problem by truncating the co- shot noise, in which case the noise process is an uncorrelated variancematrix at some maximum lag, i.e., by considering the Poisson process that in the limit of large of counts is truncated χ2 statistic well-approximated by an uncorrelated , N L N 2 2 ˆ −1 1 ǫ χ (L)= ri(Σ )i(i+l)ri+l , (9) (~ǫ;~q)= (ǫ;σ2)= exp − i , (3) D N √ 2 2σ2 i=1 l=−L i=1 2πσ X 1

FIG. 1.— Examples of 1/ f γ noise. Uncorrelated (white) noise corresponds to γ = 0. “Pink” noise corresponds to γ = 1. “Red” noise or corresponds to γ = 2. These time series were generated using the wavelet-based method described in § 4. equations analogous to the Fourier series and its inversion is The detail functions dm(t) belong to a function space Wm(t), ∞ ∞ the orthogonal complement of the resolution Vm. m m With these conditions and definitions, the orthogonal ba- ǫ(t)= ǫn ψn (t) (13) m sis functions of Wm are the wavelet functions ψ (t), ob- m=−∞ n=−∞ n X∞ X tained by translating and dilating some mother wavelet ψ(t). m m m The orthogonal basis functions of Vm are denoted φ (t), ob- ǫn = ǫ(t)ψn (t)dt (14) n −∞ tained by translating and dilating a so-called “father” wavelet Z m φ(t). Thus, the mother wavelet spawns the basis of the detail where ǫn is referred to as the wavelet coefficient of ǫ(t) at resolution m and translation n. spaces, and the father wavelet spawns the basis of the resolu- tion spaces. They have complementary characteristics, with 3.1. The wavelet transform as a multiresolution analysis the mother acting as a high-pass filter and the father acting as 3 We will see shortly that some extra terms are required in a low-pass filter. In Eqn. (16), the approximation ǫk(t) is a member of Vk, Eqn. (14) for real signals with some minimum and maximum k which is spanned by the functions φn(t), and dm(t) is a mem- resolution. To explain those terms it is useful to describe the m wavelet transform as a multiresolution analysis, in which we ber of Wm, which is spanned by the functions ψn (t). Thus we consider successively higher-resolution approximations of a may rewrite Eqn. (16) as m signal. An approximation with a resolution of 2 samples per ∞ M ∞ unit time is a member of a resolution space V . Following k k m m m ǫM(t)= ǫ¯ φ (t) + ǫ ψ (t). (17) Wornell (1996) we impose the following conditions: n n n n n=−∞ m=k n=−∞ −m X X X 1. if f (t) Vm then for some n, f (t − 2 n) Vm m ¯m ∈ ∈ The wavelet coefficients ǫn and the scaling coefficients ǫn are given by 2. if f (t) Vm then f (2t) Vm+1. ∈ ∈ ∞ The first condition requires that Vm contain all translations (at m m ǫn = ǫ(t)ψn (t)dt (18) the resolution scale) of any of its members, and the second −∞ condition ensures that the sequence of resolutions is nested: Z ∞ ¯m m Vm is a subset of the next finer resolution Vm+1. In this way, if ǫn = ǫ(t)φn (t)dt (19) − ǫm(t) Vm is an approximation to the signal ǫ(t), then the next ∞ ∈ Z finer approxmation ǫm+1(t) Vm+1 contains all the information ∈ Eqn. (17) reduces to the wavelet-only equation (13) for the encoded in ǫm(t) plus some additional detail dm(t) defined as case of a continuously sampled signal ǫ(t), when we have ac- − 4 dm(t) ǫm+1(t) − ǫm(t). (15) cess to all resolutions m from to . ≡ There are many suitable choices∞ for∞φ and ψ, differing in We may therefore build an approximation at resolution M by the tradeoff that must be made between smoothness and lo- starting from some coarser resolution k and adding successive detail functions: 3 More precisely, the wavelet and scaling functions considered here are M “quadrature mirror filters” (Mallat 1999). 4 + The signal must also be bounded in order for the approximation to the ǫM(t)= ǫk(t) dm(t) (16) signal at infinitely coarse resolution to vanish, i.e., limk→−∞ ǫk(t)=0. m=k X 5 calization. The simplest choice is due to Haar (1910): analysis using this basis. Press et al. (2007) provide code to implement the wavelet transform in this basis. 1 if0 < t 1 γ φ(t)= 0 otherwise≤ . (20) 3.3. Wavelet transforms and 1/ f noise  As alluded in § 3, the wavelet transform acts as a nearly di- 1 if − 1 < t 0 2 ≤ agonalizing operator for the covariance matrix in the presence ψ(t)= −1 if0 < t 1 (21) γ m  ≤ 2 of 1/ f noise. The wavelet coefficients ǫn of such a noise 0 otherwise process are zero-mean, nearly uncorrelated random variables. Specifically, the covariance between scales m, m′ and transla- The left panel of Fig. 2 shows several elements of the approx- tions n, n′ is (Wornell 1996, p. 65) imation and detail bases for a Haar multiresolution analysis. ′ − The left panels of Fig. 3 illustrate a Haar multiresolution anal- m m 2 γm ′ ′ ǫn ǫn′ σr 2 δm,m δn,n . (24) ysis for an arbitrarily chosen signal ǫ(t), by plotting both the h i≈ The wavelet basis is also convenient for the case in which approximations ǫm(t) and details dm(t) at several resolutions  m. The Haar analysis is shown for pedagogic purposes only. the noise is modeled as the sum of an uncorrelated component In practice we found it advantageous to use the more compli- and a correlated component, cated fourth-order Daubechies wavelet basis, described in the ǫ(t)= ǫ0(t) + ǫγ(t), (25) next section, for which the elements and the multiresolution analysis are illustrated in the right panels of Fig. 2-3. where ǫ0(t) is a Gaussian white noise process (γ =0) with a γ single noise parameter σw, and ǫγ (t) has ( f )= A/ f . In the S 3.2. The Discrete Wavelet Transform context of transit photometry, white noise might arise from photon-counting (and in cases where the detector is Real signals are limited in resolution, leading to finite M well-calibrated, σw is a known constant), while the γ = 0 term and k in Eqn. (17). They are also limited in time, allowing represents the “rumble” on many time scales due to6 instru- only a finite number of translations Nm at a given resolution mental, atmospheric, or astrophysical sources. For the noise m. Starting from Eqn. (17), we truncate the sum over n and process of Eqn. (25) the covariance between wavelet coeffi- reindex the resolution sum such that the coarsest resolution is cients is k = 1, giving ′ − m m 2 γm + 2 ′ ′ ǫn ǫn′ σr 2 σw δm,m δn,n . (26) N M N h i≈ 1 m ¯m ¯1 1 + m m and the covariance betwen the scaling coefficients ǫn is ǫM(t)= ǫnφn(t) ǫn ψn (t) (22)  − n=1 m=2 n=1 ǫ¯mǫ¯m σ22 γmg(γ) + σ2 (27) X XX h n n i≈ r w where we have taken t = 0 to be the start of the signal. Since where g(γ) is a constant of order unity; for the purposes of −M there is no information on timescales smaller than 2 , we this work g(1) = (2ln2)−1 0.72 (Fadili & Bullmore 2002). need only consider ǫM(ti) at a finite set of times ti: Eqns. (26) and (27) are the≈ key mathematical results that form the foundation of our algorithm. For proofs and further de- N1 M Nm ¯1 1 + m m tails, see Wornell (1996). ǫ(ti)= ǫnφn(ti) ǫn ψn (ti). (23) It should be noted that the correlations between the wavelet n=1 m=2 n=1 X XX and scaling coefficients are small but not exactlyzero. The de- Eqn. (23) is the inverse of the Discrete Wavelet Transform cay rate of the correlations with the resolution index depends (DWT). Unlike the continuous transform of Eqn. (13), the on the choice of wavelet basis and on the spectral index γ. DWT must include the coarsest level approximation (the first By picking a wavelet basis with a higher number of vanishing term in the preceding equation) in order to preserve all the moments, we hasten the decay of correlations. This is why information in ǫ(ti). For the Haar wavelet, the coarsest ap- we chose the Daubechies 4th-order basis instead of the Haar M proximation is the mean value. For data sets with N = n02 basis. In the numerical experiments decribed in § 4, we found uniformly spaced samples in time, we will have access to a the to be negligible for the purposes of parameter m−1 estimation. In addition, the compactness of the Daubechies maximal scale M, as in Eqn. (23), with Nm = n02 . A crucial point is the availability of the Fast Wavelet Trans- 4th-order basis reduces artifacts arising from the assumption form (FWT) to perform the DWT (Mallat 1989). The FWT is of a periodic signal that is implicit in the FWT. M a pyramidal algorithm operating on data sets of size N = n02 3.4. The whitening filter M returning n0(2 − 1) wavelet coefficients and n0 scaling coef- ficients for some n > 0, M > 0. The FWT is a computation- Given an observation of noise ǫ(t) that is modeled as in 0 Eqn. (25), we may estimate the γ = 0 component by rescal- ally efficient algorithm that is easily implemented (Press et al. 6 2007) and has O(N) time-complexity (Teolis 1998). ing the wavelet and scaling coefficients and filtering out the Daubechies (1988) generalized the Haar wavelet into a white component: larger family of wavelets, categorized according to the num- N1 − σ22 γg(γ) ber of vanishing moments of the mother wavelet. The Haar ǫ (t)= r ǫ¯1φ1(t) + (28) γ 2 −γ + 2 n n wavelet has a single vanishingmoment and is the first member σr 2 g(γ) σw n=1   of the family. In this work we used the most compact mem- X M Nm 2 −γm ber (in time and frequency), ψ =4 and φ =4 , which is well σr 2 m m γ D A − ǫn ψn (t). (29) suited to the analysis of 1/ f noise for 0 <γ< 4 (Wornell σ22 γm + σ2 m m m=2 n=1  r w  1996). We plot 4 n and 4 n in the time-domain for several n, XX m in Fig. 2, illustratingD theA rather unusual functional form of We may then proceed to subtract the estimate of the corre- 4 . The right panel of Fig. 3 demonstrates a multiresolution lated component from the observed noise, ǫ0(t)= ǫ(t) − ǫγ(t) D 6

FIG. 2.— Examples of discrete wavelet and scaling functions, for N = 2048. Left.—Haar wavelets and the corresponding father wavelets, also known as m m m m 2nd-order Daubechies orthonormal wavelets or 2Dn and 2An . Right.—4th-order Daubechies orthonormal wavelets, or 4Dn and 4An .

3 FIG. 3.— Illustration of a multiresolution analysis, for the function ǫ(t) = sin[4π(t/1024) ] (dashed line). Plotted are the approximations ǫm(t) to the function at successive resolutions, along with the detail functions dm(t). Left.—Using the Haar wavelet basis. Right.—Using the 4th-order Daubechies wavelet basis. (Wornell 1996, p. 76). In this way the FWT can be used to m and translation n:

“whiten” the noise. − n 2m 1 2 M 0 1 rm = exp − n L  2 2σ2  m=2 n=1 2πσW " W # 3.5. The wavelet-based likelihood Y Y  n p 2 Armed with the preceding theory, we rewrite the likelihood 0 r¯1  1 − n  functionof Eqn. (6) in the wavelet domain. First we transform exp 2 (32) ×  2 2σ  the residuals ri yi − f (ti; ~p), giving n=1 2πσ " S # ≡ Y S  q m m − m m + m where   rn = yn fn (~p)= ǫγ,n ǫ0,n (30) 2 2 −γm + 2 ¯1 ¯1 − ¯1 ¯1 + ¯1 σW = σr 2 σw (33) rn = yn fn (~p)= ǫγ,n ǫ0,n (31) 2 2 −γ + 2 σS = σr 2 g(γ) σw (34) m m where yn and fn (~p) are the discrete wavelet coefficients of are the of the wavelet and scaling coefficients re- ¯1 ¯1 the data and the model. Likewise, yn and fn (~p) are the n0 spectively. For a data set with N points, calculating the like- scaling coefficients of the data and the model. Given the di- lihood function of Eqn. (32) requires multiplying N Gaussian agonal covariance matrix shown in Eqns. (26) and (27), the functions. The additional step of computing the FWT of the likelihood is a product of Gaussian functions at each scale residuals prior to computing adds O(N) operations. Thus, L L 7 the entire calculation has a time-complexity O(N). and to two other analysis methods drawn from the literature. For this calculation we must have estimators of the three Because we used simulated transit light curves with known noise parameters γ, σr and σw. These may be estimated sep- noise and transit parameters, the “truth” was known precisely, arately from the model parameters ~p, or simultaneously with allowing both the absolute and relative merits of the methods the model parameters. For example, in transit photometry, the to be evaluated. data obtained outside of the transit may be used to estimate the noise parameters, which are then used in Eqn. (32) to esti- 4.1. Estimating the midtransit time: Known noise parameters mate the modelparameters. Or, in a single step we could max- In this section we consider the case in which the noise pa- imize Eqn. (32) with respect to all of , , and p. Fitting γ σr σw ~ rameters , , and are known with negligible error. We for both noise and transit parameters simultaneously is poten- γ σr σw havein mind a situation in which a long series of out-of-transit tially problematic, because some of the correlated noise may data are available, with stationary noise properties. be “absorbed” into the choices of the transit parameters, i.e., We generated transit light curves with known transit pa- the errors in the noise parameters and transit parameters are rameters p, contaminated by an additive combination of a themselves correlated. This may cause the noise level and the ~ white and a correlated (1/ f γ) noise source. Then we used an parameter uncertainties to be underestimated. Unfortunately, MCMC method to estimate the transit parameters and their there are many instances when one does not have enough out- 68.3% confidence limits. (The technique for generating noise of-transit data for the strict separation of transit and noise pa- and the MCMC method are described in detail below.) For rameters to be feasible. each realization of a simulated light curve, we estimated tran- In practice the optimization can be accomplished with an sit parameters using the likelihood defined either by Eqn. (6) iterative routine [such as AMOEBA, Powell’s method, or a for the white analysis, or Eqn. (32) for the wavelet analysis. conjugate-gradient method; see Press et al. (2007)]. Confi- For a given parameter p , the estimator pˆ was taken to be dence intervals can then be defined by the contoursof constant k k the median of the values in the and σˆ was likelihood. Alternatively one can use a Monte Carlo Markov pk taken to be the standard deviation of those values. To assess Chain [MCMC; see, e.g., Gregory (2005)], in which case the the results, we considered the “number-of-sigma” statistic jump-transition likelihood would be given by Eqn. (32). The advantages of the MCMC method have led to its adoption by (pˆk − pk)/σˆp . (35) many investigators (see, e.g., Holman et al. 2006, Burke et N≡ k al. 2007, Collier Cameron et al. 2007). For that method, com- In words, is the number of standard deviations separating N putational speed is often a limiting factor, as a typical MCMC the parameter estimate pˆk from the true value pk. If the error analysis involves several million calculations of the likelihood in pk is Gaussian, then a perfect analysis method should yield function. results for with an expectation value of 0 and variance of 1. If we findN that the variance of is greater than one, then N 3.6. Some practical considerations we have underestimated the error in pˆk and we may attribute Some aspects of real data do not fit perfectly into the too much significance to the result. On the other hand, if the requirements of the DWT. The time sampling of the data variance of is smaller than one, then we have overestimated N should be approximately uniform, so that the resolution scales σpk and we may miss a significant discovery. If we find that of the multiresolution analysis accurately reflect physical the mean of is nonzero then the method is biased. N timescales. This is usually the case for time-series photomet- For now, we consider only the single parameter tc, the time ric data. Gaps in a time series can be fixed by applying the of midtransit. The tc parameter is convenient for this analy- DWT to each uninterrupted data segment, or by filling in the sis as it is nearly decoupled from the other transit parameters missing elements of the residual series with zeros. (Carter et al. 2008). Furthermore, as mentioned in the intro- The FWT expects the number of data points to be an inte- duction, the measurement of the midtransit time cannot be gral multiple of some integral power of two. When this is not improved by observing other transit events, and variations in the case, the time series may be truncated to the nearest such the transit interval are possible signs of additional gravitating boundary; or it may be extended using a periodic boundary bodies in a planetary system. condition, mirror reflection, or zero-padding. In the numeri- The noise was synthesized as follows. First, we generated cal experiments described below, we found that zero-padding a sequence of N = 1024 independent random variables obey- has negligible effects on the calculation of likelihood ratios ing the variance conditions from Eqns. (26) and (27) for 1023 and parameter estimation. wavelet coefficients over 9 scales and a single scaling coeffi- The FWT generally assumes a periodic boundary condition cient at the coarsest resolution scale. We then performed the for simplicity of computation. A side effect of this simplica- inverse FWT of this sequence to generate our noise signal. In tion is that information at the beginning and end of a time se- this way, we could select exact values for γ, σr, and σw. We ries are artificially associated in the wavelet transform. This also needed to find the single parameter σ for the white-noise is one reason why we chose the 4th-order Daubechies-class analysis; it is not simply related to the parameters γ, σr, and wavelet basis, which is well localized in time, and does not σw. In practice, we found σ by calculating the median sample significantly couple the beginning and the end of the time se- variance among 104 unique realizations of a noise source with ries except on the coarsest scales. fixed parameters γ, σr, and σw. For the transit model, we used the analytic formulas of 4. NUMERICAL EXPERIMENTS WITH TRANSIT LIGHT CURVES Mandel & Agol (2002), with a planet-to-star ratio of Rp/R⋆ = We performed many numerical experiments to illustrate and 0.15, a normalized orbital distance of a/R⋆ = 10, and an or- test the wavelet method. These experiments involved estimat- bital inclination of i =90◦, as appropriatefor a gas giantplanet ing the parameters of simulated transit light curves. We also in a close-in orbit around a K star. These correspond to a compared the wavelet analysis to a “white” analysis, by which fractional loss of light δ =0.0225, duration T =1.68 hr, and we mean a method that assumes the errors to be uncorrelated, partial duration τ =0.152 hr. We did not include the effect 8 of limb darkening, as it would increase the computation time TABLE 1 and has little influence on the determination of tc (Carter et ESTIMATES OF MID-TRANSIT TIME, tc , FROM DATA WITH KNOWN NOISE al. 2009). Each simulated light curve spanned 3 hr centered PROPERTIES on the midtransit time, with a time sampling of 11 s, giving ˆ a 1024 uniformly spaced samples. A noise-free light curve is Method α hσtc i [sec] hN i σN prob(N > 1) prob(best) shown in Fig. 4. −3 For the noise model, we chose σw =1.35 10 and γ = 1, White 0 4.1 +0.004 0.95 29% 50% × − and tried different choices for σr. We denote by α the ratio 1/3 4.3 0.005 1.93 61% 39% 2/3 5.0 +0.005 3.04 75% 35% of the rms values of the correlated noise component and the − white noise component.5 The example in Fig. 4 has α =1/3. 1 5.9 0.036 3.82 79% 34% As α is increased from zero, the correlated component be- comes more important, as is evident in the simulated data Wavelet 0 4.0 +0.005 0.95 29% 50% 1/3 7.2 −0.004 0.93 28% 61% plotted in Fig. 5. Our choice of σw corresponds to a preci- − −4 2/3 11.5 0.004 0.94 28% 65% sion of 5.8 10 per minute-equivalent sample, and was in- 1 16.0 −0.001 0.95 29% 66% spired by the× recent work by Johnson et al. (2009) and Winn −4 et al. (2009), which achieved precisions of 5.4 10 and a The probability that the analysis method (white or wavelet) returns an estimate −4 × 4.0 10 per minute-equivalent sample, respectively. Based of tc that is closer to the true value than the other method. × on our survey of the literature and our experience with the column in Table (1), where we report the percentage of cases Transit Light Curve project (Holman et al. 2006, Winn et in which the analysis method (white or wavelet) produces an al. 2007), we submit that all of the examples shown in Fig. 5 estimate of tc that is closer to the truth. For α = 1 the wavelet are “realistic” in the sense that the bumps, wiggles, and ramps analysis gives more accurate results 66% of the time. resemble features in actual light curves, depending on the in- strument, observing site, weather conditions, and target star. 4.2. Estimating the midtransit time: Unknown noise For a given choice of α, we made 10,000 realizations of the parameters simulated transit light curve with 1/ f noise. We then con- structed two Monte Carlo Markov Chains for t starting at In this section we consider the case in which the noise pa- c rameters are not known in advance. Instead the noise param- the true value of tc = 0. One chain was for the white analy- sis, with a jump-transition likelihood given by Eqn. (6). The eters must be estimated based on the data. We did this by in- other chain was for the wavelet analysis, using Eqn. (32) in- cluding the noise parameters as adjustable parameters in the stead. Both chains used the Metropolis-Hastings jump con- Markov chains. In principle this could be done for all three dition, and employed perturbation sizes such that 40% of noise parameters γ, σr, and σw, but for most of the experi- jumps were accepted. Initial numerical experiments≈ showed ments presented here we restricted the problem to the case γ = 1. This may be a reasonable simplification, given the pre- that the autocorrelation of a given Markov chain for tc is sharply peaked at zero lag, with the autocorrelation dropping ponderance of natural noise sources with γ = 1 (Press 1978). Some experiments involving noise with γ = 1 are described at below 0.2 at lag-one. This ensured good convergence with 6 chain lengths of 500 (Tegmark et al. 2004). Chain histograms the end of this section. were also inspected visually to verify that the distribution was We also synthesized the noise with a non-wavelet tech- ˆ ˆ nique, to avoid “stacking the deck” in favor of the wavelet smooth. We recorded the median tc and standard deviation σtc for each chain and constructed the statistic for each sepa- method. We generated the noise in the frequency domain, as rate analysis (white or wavelet). Finally, weN found the median follows. We specified the amplitudes of the Fourier coeffi- and standard deviation of over all 10,000 noise realizations. cients using the assumed functional form of the power spec- N tral density [ ( f ) 1/ f ], and drew the phases from a uniform Fig. 6 shows the resulting distributions of , for the par- S ∝ − ticular case α =1/3. Table 1 gives a collectionN of results for distribution between π and π. The correlated noise in the the choices α =0, 1/3, 2/3, and 1. The mean of is zero time domain was found by performing an inverse Fast Fourier for both the white and wavelet analyses: neither methodN is Transform. We rescaled the noise such that the rms was α biased. This is expected, because all noise sources were de- times the specified σw. The normally-distributed white noise scribed by zero-mean Gaussian distributions. However, the was then added to the correlatednoise to create the total noise. widths of the distributions of show that the white analy- This in turn was added to the idealized transit model. N For each choice of α, we made 10,000 simulated transit sis underestimates the error in tc. For a transit light curve constructed with equal parts white and 1/ f noise (α = 1), the light curves and analyzed them with the MCMC method de- scribed previously. For the white analysis, the mid-transit white analysis gave an estimate of tc that differs from the true value by more than 1 σ nearly 80% of the time. The factor by time tc and the single noise parameter σ were estimated using the likelihood defined via Eqn. (6). For the wavelet analysis which the white analysis underestimates the error in tc appears to increase linearly with α. In contrast, for all values of α, the we estimated tc and the two noise parameters σr and σw using wavelet analysis maintains a unit variance in , as desired. the likelihood defined in Eqn. (32). The success of the wavelet method is partiallyN attributed to Table 3 gives the resulting statistics from this experiment, in the larger (and more appropriate) error intervals that it returns the same form as were given in Table 1 for the case of known ˆ noise parameters. (This table also includes some results from for tc. It is also partly attributable to an improvement in the ˆ ˆ § 4.4, which examines two other methods for coping with cor- accuracy of tc itself: the wavelet method tends to produce tc values that are closer to the true t . This is shown in the final related noise.) Again we find that the wavelet method pro- c duces a distribution of with unit variance, regardless of 5 N We note that although σw is the rms of the white noise component, σr is α; and again, we find that the white analysis underestimates generally not the rms of the correlated component. The notation is unfortu- the error in tc. In this case the degree of error underestima- nate, but follows that of Wornell (1996). tion is less severe, a consequence of the additional freedom 9

FIG. 4.— Constructing a simulated transit light curve with correlated noise. The total noise is the sum of uncorrelated with standard deviation σw (upper left panel) and correlated noise with a power S( f ) ∝ 1/ f and an rms equal to σw/3 (upper right panel). The total noise (middle left panel) is added to an idealized transit model (middle right panel) to produce the simulated data (bottom panel). in the noise model to estimate σ from the data. The wavelet TABLE 2 method also gives more accurate estimates of tc than the white EFFECT OF TIME SAMPLING method, although the contrast between the two methods is ON THE WHITE ANALYSIS smaller than it was with for the case of known noise parame- a ters. N Cadence [sec] σN Our numerical results must be understood to be illustrative, and not universal. They are specific to our choices for the 256 42.2 1.72 noise parameters and transit parameters. Via further numer- 512 21.1 2.04 ical experiments, we found that the width of in the white 1024 10.5 2.69 N 2048 5.27 3.49 analysis is independent of σw, but it does depend on the time 4096 2.63 4.39 sampling. In particular, the width grows larger as the time sampling becomes finer (see Table 2). This can be understood a The number of samples in a as a consequence of the long-range correlations. The white 3 hr interval. analysis assumes that the increased number of data points will lead to enhanced precision, whereas in reality, the correlations negate the benefit of finer time sampling. noise fraction was set to α =1/2 for these tests. The results Table 4 gives the results of additional experiments with γ = show that even when is falsely assumed to be unity, the 6 γ 1. In those cases we created simulated noise with γ =1 butin wavelet analysis still produces better estimates of t and more 6 c the course of the analysis we assumed γ = 1. The correlated reliable error bars than the white analysis. 10

FIG. 5.— Examples of simulated transit light curves with different ratios α = rmsr/rmsw between the rms values of the correlated noise component and white noise component.

FIG. 6.— Histograms of the number-of-sigma statistic N for the midtransit time tc. Each distribution shows the probability of estimating a value for tc that differs by N σ from the true value. The simulated data were created by adding an idealized transit model to a noise source that is the sum of uncorrelated noise and 1/ f noise with equal variances (α = 1; see the text). 11

TABLE 3 ESTIMATES OF tc FROM DATA WITH UNKNOWN NOISE PROPERTIES

ˆ a Method α hσtc i [sec] hN i σN prob(N > 1) prob(better)

White 0 4.0 −0.011 0.97 31% − 1/3 4.2 +0.010 1.70 57% − 2/3 4.9 +0.012 2.69 73% − 1 5.8 +0.023 3.28 78% −

Wavelet 0 4.5 −0.009 0.90 26% 50% 1/3 6.9 −0.003 1.03 33% 56% 2/3 11.2 −0.005 1.07 35% 57% 1 15.7 −0.007 1.09 36% 57%

Time-averaging 0 4.4 −0.006 0.88 26% 50% 1/3 6.8 +0.009 1.15 36% 50% 2/3 11.6 −0.012 1.24 40% 50% 1 17.6 +0.007 1.21 38% 50%

Residual-permutation 0 3.5 −0.012 1.16 37% 50% 1/3 6.6 +0.013 1.24 37% 50% 2/3 11.8 −0.014 1.28 38% 49% 1 17.3 +0.008 1.30 38% 48% a The probability that the analysis method returns an estimate of tc that is closer to the true value than the white analysis. 12

lihood. We estimated tc and σtc , and calculated . We did TABLE 4 this for 5,000 realizations and determined σN , theN variance in ESTIMATES OF tc FROM DATA WITH UNKNOWN NOISE PROPERTIES , across this sample. We repeated this process for different N a ˆ b choices of the maximum lag L. Fig. (8) shows the dependence Method γ hσtc i [sec] hN i σN prob(N > 1) prob(best) of σN upon the maximum lag L. The time-domain method works fine, in the sense that when White 0.5 4.5 −0.025 1.34 47% 50% 1.5 4.6 +0.020 3.10 77% 32% enough non-diagonal elements in the covariance matrix are retained, the parameter estimation is successful. We find that −β σN approaches unity as L with β =0.15, 0.25 for α =1/3, Wavelet 0.5 6.7 −0.021 0.97 30% 50% + 2/3, respectively. However, to match the reliability of the 1.5 6.9 0.002 1.17 39% 68% wavelet method, a large number of lags must be retained. To a γ reach σN = 1.05, we need L 50 for α = 1/3 or L 75 The spectral exponent of the Power Spectral Density, S( f ) ∝ 1/ f . for α =2/3. In our implementation,≈ the calculation based≈ on b The probability that the analysis method (white or wavelet) returns an estimate of tc that is closer to the true value than the other method. the truncated covariance matrix [Eqn. (9)] took 30–40 times longer than the calculation based on the wavelet likelihood 4.3. Runtime analysis of the time-domain method [Eqn. (32)]. Having established the superiority of the wavelet method This order-of-magnitude penalty in runtime is bad enough, over the white method, we wish to show that the wavelet but the real situation may be even worse, because one usually method is also preferable to the more straightforward ap- has access to a single noisy estimate of the autocovariance proach of computing the likelihood function in the time do- matrix. Or, if one is using an ARMA model, the estimated pa- main with a non-diagonal covariance matrix. The likelihood rameters of the model might be subject to considerable uncer- in this case is given by Eqn. (8). tainty as compared to the “exact” autocovariance employed in The time-domain calculation and the use of the covariance our numerical experiments. If it is desired to determine the matrix raised two questions. First, how well can we estimate noise parameters simultaneously with the other model param- the autocovariance R(τ) from a single time series? Second, eters, then there is a further penalty associated with inverting how much content of the resulting covariance matrix needs to the covariance matrix at each step of the calculation for use be retained in the likelihood calculation for reliable parame- in Eqn. (9), although it may be possible to circumvent that ter estimation? The answer to the first question depends on particular problem by modeling the inverse-covariance matrix whether we wish to utilize the sample autocorrelation as the directly. estimator of R(τ) or instead use a parametric model (such as an ARMA model) for the autocorrelation. In either case, our ability to estimate the autocorrelation improves with number of data samples contributing to its calculation. The second question is important because retaining the full covariance matrix would cause the computation time to scale as O(N2) and in many cases the analysis would be prohibitively slow. The second question may be reframed as: what is the mini- mum number of lags L that needs to be considered in comput- ing the truncated χ2 of Eqn. (9), in order to give unit variance in the number-of-sigma statistic for each model parameter? The time-complexity of the truncated likelihood calculation is O(NL). If L . 5 then the time-domain method and the wavelet method may have comparable computational time- complexity, while for larger L the wavelet method would offer significant advantage. We addressed these questions by repeating the experiments of the previous sections using a likelihood function based on the truncated χ2 statistic. We assumed that the parameters of the noise model were known, as in § 4.1. The noise was syn- thesized in the wavelet domain, with γ =1, σw =0.00135, and FIG. 7.— Autocorrelation functions of correlated noise. The noise was α set equal to 1/3or2/3. The parameters of the transit model computed as the sum of white noise with σw = 0.00135 and 1/ f noise with and the time series were the same as in § 4.1. We calculated an rms equal to ασw, for α = 1/3 or 2/3. the “exact” autocovariance function R(l) at integer lag l for a given α by averaging sample autocovariances over 50,000 noise realizations. Fig. 7 plots the autocorrelation [R(l)/R(0)] 4.4. Comparison with other methods as a function of lag for α =1/3, 2/3. We constructed the In this section we compare the results of the wavelet method Σ − stationary covariance i j = R( i j ) and computed its inverse to two methods for coping with correlated noise that are −1 | | (Σ )i j for use in Eqn. (9). drawn from the recent literature on transit photometry. The Then we used the MCMC method to find estimates and er- first of these two methods is the “time averaging” method rors for the time of midtransit, and calculated the number-of- that was propounded by Pont et al. (2006) and used in vari- sigma statistic as defined in Eqn. (35). In particular, for ous forms by Bakos et al. (2006), Gillon et al. (2006), Winn each simulatedN transit light curve, we created a Markov chain et al. (2007, 2008, 2009), Gibson et al. (2008), and others. In 2 of 1,000 links for tc, using χ (L) in the jump-transition like- one implementation, the basic idea is to calculate the sample 13

then adding them to the model light curve. In this way, the synthetic data sets have the same bumps, wiggles, and ramps as the actual data, but they are translated in time. The pa- rameter errors are given by the widths of the distributions in the parameters that are estimated from all the different real- izations of the synthetic data, and they are usually larger than the parameter errors returned by a purely white analysis. As before, we limited the scope of the comparison to the estimation of tc and its uncertainty. We created 5,000 realiza- tionsof a noise source with γ =1andagivenvalueof α (either 0,1/3,2/3, or1). We used each ofthe two approximatemeth- ˆ ods (time-averaging and residual-permutation) to calculate β and its uncertainty based on each of the 5,000 noise realiza- tions. Then we found the median and standard deviation of ˆ β/β over all 5,000 realizations. Table (3) presents the results of this experiment. Both methods, time-averaging and residual-permutation, gave more reliable uncertainties than the white method. How- ever they both underestimated the true uncertainties by ap- proximately 15-30%. Furthermore, neither method provided FIG. 8.— Accuracy of the truncated time-domain likelihood in estimating more accurate estimates of t than did the white method. For midtransit times. Plotted is the variance in the number-of-sigma statistic σN c for the midtransit time tc, as a function of the maximum lag in the truncated the time-averaging method as we have implemented it, this series. The estimates of tc were found using the truncated likelihood given in result is not surprising, for that method differs from the white Eqn. (9). method only in the inflation of the error bars by some factor β. The parameter values that maximize the likelihood func- ˆ2 variance of unbinned residuals, σ1 , and also the sample vari- tion were unchanged. ˆ2 ance of the time-averaged residuals, σn, where every n points have been averaged (creating m time bins). In the absence of correlated noise, we expect 4.5. Alternative noise models We have shown the wavelet method to work well in the σˆ2 m γ σˆ2 = 1 . (36) presence of 1/ f noise. Although this family of noise pro- n n m − 1 cesses encompasses a wide range of possibilities, the universe  ˆ2 of possible correlated noise processes is much larger. In this In the presence of correlated noise, σn differs from this ex- section we test the wavelet method using simulated data that ˆ2 ˆ pectation by a factor βn . The estimator β is then found by has correlated noise of a completely different character. In ˆ averaging βn over a range ∆n corresponding to time scales particular, we focus on a process with exclusively short-term that are judged to be most important. In the case of transit correlations, described by one of the aforementioned autore- photometry, the duration of ingress or egress is the most rel- gressive moving-average (ARMA) class of parametric noise evant time scale (corresponding to averaging time scales on models. In this way we test our method on a noise process the order of tens of minutes, in our example light curve). A that is complementaryto the longer-range correlations present white analysis is then performed, using the noise parameter in 1/ f γ noise, and we also make contact between our method ˆ σ = βσ1 instead of σ1. This causes the parameter errors σpk to and the large body of statistical literature on ARMA models. γ increase by β but does not change the parameter estimates pˆk For 1/ f noise we have shown that time-domain param- themselves.6 eter estimation techniques are slow. However, if the noise A second method is the “residual permutation” method that has exclusively short-range correlations, the autocorrelation has been used by Jenkins et al. (2002), Moutou et al. (2004), function will decay with lag more rapidly than a power law, Southworth (2008), Bean et al. (2008), Winn et al. (2008), and the truncated-χ2 likelihood [Eqn. (9)] may become com- and others. This method is a variant of a bootstrap analysis, putationally efficient. ARMA models provide a convenient in which the distribution for the parame- analytic framework for parameterizing such processes. For a ters is based on the collection of results of minimizing χ2 (as- detailed review of ARMA models and their use in statistical suming white noise) for a large number of synthetic data sets. inference, see Box & Jenkins (1976). Applications of ARMA In the traditional bootstrap analysis the synthetic data sets are models to astrophysical problems have been described by in produced by scrambling the residuals and adding them to a Koen & Lombard (1993), Konig & Timmer (1997) and Tim- model light curve, or by drawing data points at random (with mer et al. (2000). replacement) to make a simulated data set with the same num- To see how the wavelet method performson data with short- ber of points as the actual data set. In the residual permuta- range correlations we constructed synthetic transit data in tion method, the synthetic data sets are built by performing which the noise is described by a single-parameter autoregres- a cyclic permutation of the time indices of the residuals, and sive [AR(1; ψ)] model. An AR(1; ψ) process ǫ(ti) is defined by the recursive relation 6 Alternatively one may assign an error to each data point equal to the quadrature sum of the measurement error and an extra term σ (Pont et r ǫ(ti)= η(ti) + ψǫ(ti−1) (37) al. 2006). For cases in which the errors in the data points are all equal or nearly equal, these methods are equivalent. When the errors are not all the same, it is more appropriate to use the quadrature-sum approach of Pont et where η(ti) is an uncorrelated Gaussian process with width al. (2006). In this paper all our examples involve homogeneous errors. parameter σ and ψ is the sole autoregressive parameter. The 14 autocorrelation γ(l) for an AR(1; ψ) process is σ2 γ(l)= ψl. (38) 1 − ψ2 An AR(1;ψ) processis stationary so long as 0 <ψ< 1(Box& Jenkins 1976). The decay length of the autocorrelation func- tion grows as ψ is increased from zero to one. Figure (9) plots the autocorrelation function of a process that is an additive combination of an AR(1; ψ =0.95) process and a white noise process. The noise in our synthetic transit light curves was the sum of this AR(1; ψ =0.95) process, and white noise, with α =1/2 (see Fig 9). With these choices, the white method underestimates the error in tc, while at the same time the syn- thetic data look realistic. We proceeded with the MCMC method as described pre- viously to estimate the time of mid-transit. All four methods assessed in the previous section were included in this analysis, for comparison. Table 5 gives the results. The wavelet method produces more reliable error estimates than the white method.

However, the wavelet method no longer stands out as supe- FIG. 9.— An example of an autoregressive noise process with complemen- rior to the time-averaging method or the residual-permutation tary characteristics to a 1/ f γ process. The top panel shows the sum of an method; all three of these methods give similar results. This AR(1) process with ψ = 0.95 and white noise. The correlated and uncorre- illustrates the broader point that using any of these methods lated components have equal variances (α = 0.5). is much better than ignoring the noise correlations. The re- sults also show that although the wavelet method is specif- of a known transiting planet. Typically an observer would fit γ ically tuned to deal with 1/ f noise, it is still useful in the the midtransit times tc,i, to a model in which the transits are presence of noise with shorter-range correlations. strictly periodic: It is beyond the scope of this paper to test the applicabil- t =t + E P (39) ity of the wavelet method on more general ARMA processes. c,i c,0 i Instead we suggest the following approach when confronted for some integers Ei and constants tc,0 and P. Then, the residu- with real data [see also Beran (1994)]. Calculate the sample als would be computed by subtracting the best-fit model from autocorrelation, and power spectral density, based on the out- the data, and a test for anomalies would be performed by as- of-transit data or the residuals to an optimized transit model. sessing the likelihood of obtaining those residuals if the lin- For stationary processes these two indicators are related as ear model were correct. Assuming there are N data points described in § 2. Short-memory, ARMA-like processes can with normally-distributed, independent errors, the likelihood 2 2 be identified by large at small lags or by fi- is given by a χ -distribution, prob(χ , Ndof), where nite power spectral density at zero frequency. Long-memory processes (1/ f γ) can be identified by possibly small but non- t − (t + E P) 2 χ2 = c,i c,0 i (40) vanishing autocorrelationat longer lags. Processes with short- σ i tc,i range correlations could be analyzed with an ARMA model X  of the covariance matrix [see Box & Jenkins (1976)], or the and Ndof = N − 2 is the number of degrees of freedom. Values truncated-lag covariance matrix, although a wavelet-based of χ2 with a low probability of occurrence indicate the linear analysis may be sufficient as well. Long-memory processes model is deficient, that there are significant anomalies in the are best analyzed with the wavelet method as described in this timing data, and that further observations are warranted. paper. We produced 10 simulated light curves of transits of the It should also be noted that extensions of ARMA mod- γ particular planet GJ 436b, a Neptune-sized planet transiting els have been developed to mimic long-memory, 1/ f pro- an M dwarf (Butler et al. 2004, Gillon et al. 2007) which has cesses. In particular, fractional autoregressive integrated γ been the subject of several transit-timing studies (see, e.g., moving-average models (ARFIMA) describe “nearly” 1/ f Ribas et al. 2008, Alonso et al. 2008, Coughlin et al. 2008). stationary processes, according to the criterion described by Our chosen parameters were Rp/R⋆ =0.084, a/R⋆ = 12.25, Beran (1994). As is the case with ARMA models, ARFIMA i =85.94 deg, and P =2.644 d. This gives δ =0.007, T =1 hr, models enjoy analytic forms for the likelihood in the time- and τ =0.24 hr. We chose limb-darkening parameters as ap- domain. Alas, as noted by Wornell (1996) and Beran (1994), propriate for the SDSS r band (Claret 2004). We assumed that the straightforward calculation of this likelihood is compu- γ 10 consecutive transits were observed, in each case giving 512 tationally expensive and potentially unstable. For 1/ f pro- uniformly-sampled flux measurements over 2.5 hours cen- cesses, the wavelet method is probably a better choice than tered on the transit time. Noise was synthesized in the Fourier any time-domain method for calculating the likelihood. domain(as in § 4.2), with a white component σw =0.001anda 1/ f component with rms 0.0005 (α =1/2). The 10 simulated 4.6. Transit timing variations estimated from a collection of light curves are plotted in Fig. (10). Visually, they resemble light curves the best light curves that have been obtained for this system. We present here an illustrative calculation that is relevant To estimate the midtransit time of each simulated light to the goal of detecting planets or satellites through the per- curve, we performed a wavelet analysis and a white analysis, turbations they produce on the sequence of midtransit times allowing only the midtransit time and the noise parameters to 15

TABLE 5 ESTIMATES OF tc FROM DATA WITH AUTOREGRESSIVE CORRELATED NOISE

ˆ a Method hσtc i [sec] hN i σN prob(N > 1) prob(better) White 4.5 −0.010 2.50 70% − Wavelet 8.7 −0.016 1.33 44% 51% Time-averaging 9.9 −0.010 1.25 40% 49% Residual-permutation 10.2 −0.010 1.23 38% 51%

a The probability that the analysis method returns an estimate of tc that is closer to the true value than the white analysis. 4.7. Estimation of multiple parameters TABLE 6 LINEARFITSTOESTIMATEDMIDTRANSITTIMES Thus far we have focused exclusively on the determination of the midtransit time, in the interest of simplicity. However, 2 2 2 Method Fitted Period / True Period χˆ /Ndof prob(χ < χˆ ) there is no obstacle to using the wavelet method to estimate White 1.00000071 ± 0.00000043 2.25 98% multiple parameters, even when there are strong degeneracies Wavelet 1.00000048 ± 0.00000077 0.93 51% among them. In this section we test and illustrate the abilityof the wavelet method to solve for all the parameters of a transit vary while fixing the other parameter values at their true val- light curve, along with the noise parameters. ues. We used the same MCMC technique that was described We modeled the transit as in §§ 4.1 and 4.2. The noise in § 4.2. Each analysis method produced a collection of 10 was synthesized in the frequency domain (as in § 4.2), using midtransit times and error bars. These 10 data points were σw =0.0045, γ =1, and α =1/2. The resulting simulated light then fitted to the of Eqn. (39). Fig. (11) shows curve is the upper time series in Fig. 12. We used the MCMC − the residuals of the linear fit (observed calculated). Table 6 method to estimate the transit parameters Rp/R ,a/R ,i,tc { ⋆ ⋆ } gives the best-fit period for each analysis (wavelet or white), and the noise parameters σr,σw (again fixing γ =1 for sim- along with the associated values of χ2. plicity). The likelihood was{ evaluated} with either the wavelet As was expected from the results of § 4.2, the white analy- sis gave error bars that are too small, particularly for epochs4 and 7. As a result, the practitionerof the white analysis would have rejected the hypothesis of a constant orbital period with 98% confidence. In addition, the white analysis gave an es- timate for the orbital period that is more than 1σ away from the true value, which might have complicated the planning and execution of future observations. The wavelet method, in contrast, neither underestimated nor overestimated the errors, 2 giving χ Ndof in excellent agreement with the hypothesis of a constant≈ orbital period. The wavelet method also gave an estimate for the orbital period within 1σ of the true value.

FIG. 10.— Simulated transit observations of the “Hot Neptune” GJ 436. Arbitrary vertical offsets have been applied to the light curves, to separate them on the page. 16

FIG. 11.— Transit timing variations estimated from simulated transit obser- vations of GJ 436b. Each panel shows the residuals (observed − calculated) of a linear fit to the estimated midtransit times. The midtransit times were estimated with a wavelet analysis and also with a white analysis, as described FIG. 12.— Wavelet analysis of a single simulated transit light curve. Top.— in the text. The dashed lines indicate the 1 σ errors in the linear model. Simulated light curve with correlated noise. The jagged line is the best- fitting transit model plus the best-fitting model of the 1/ f component of the method [Eqn. (32)] or the white method [Eqn. (6)]. noise. Bottom.—Simulated light curve after applying the whitening filter of Fig. 13 displays the results of this analysis in the form of the Eqn. (29), using the noise parameters estimated from the wavelet analysis. posterior distribution for the case of tc, and the joint posterior The solid line is the best-fitting transit model. confidence regions for the other cases. The wavelet method gives larger (and more appropriate) confidence regions than wavelet transforms are available. We have tested and illus- the white analysis. In accordance with our previous findings, trated this technique, and compared it to other techniques, us- the white analysis underestimates the error in tc and gives an ing numerical experiments involving simulated photometric estimate of tc that differs from the true value by more than observations of exoplanetary transits. 1σ. The wavelet method gives better agreement. Both anal- For convenience we summarize the likelihood calculation yses give an estimate for Rp/R⋆ that is smaller than the true here: value of 0.15, but in the case of the white analysis, this shift is deemed significant, thereby ruling out the correct answer Given the N data points y(ti) obtained at evenly-spaced • with more than 95% confidence. In the wavelet analysis, the times ti, subtract the model fi(ti; ~p) with model param- true value of Rp/R⋆ is well within the 68% confidence re- eters ~p to form the N residuals r(ti) y(ti) − f (ti; ~p). gion. Both the wavelet and white analyses give accurate val- ≡ ues of a/R⋆ and the inclination, and the wavelet method re- If N is not a multiple of a power of two, either truncate ports larger errors. As shown in Fig. (13), the wavelet method • the time series or enlarge it by padding it with zeros, M was successful at identifying the parameters (α and σw) of the until N = n02 for some n0 > 0, M > 0. underlying 1/ f noise process. Fig. 12 shows the best-fitting transit model, and also illus- Apply the Fast Wavelet Transform (FWT) to the resid- • M − m trates the action of the “whitening” filter that was described uals to obtain n0(2 1) wavelet coefficients rn and n0 ¯1 in § 3.4. The jagged line plotted over the upper time series is scaling coefficients rn. the best estimate of the 1/ f contribution to the noise, found For stationary, Gaussian noise built from an additive by applying the whitening filter [Eqn. (29)] to the data using • the estimated noise parameters. The lower time series is the combination of uncorrelated and correlated noise (with Power Spectral Density ( f ) 1/ f γ ), the likelihood whitened data, in which the 1/ f component has been sub- S ∝ tracted. Finally, in Fig. 14 we compare the estimated 1/ f for the residuals r(ti) is given by − noise component with the actual 1/ f component used to gen- M n 2m 1 2 erate the data. Possibly, by isolating the correlated component 0 1 rm = exp − n in this way, and investigating its relation to other observable L  2 2σ2  m=2 n=1 2πσW " W # parameters, the physical origin of the noise could be identified Y Y  and understood. n p 2 0 r¯1  1 − n  SUMMARY AND DISCUSSION exp 2 (41) 5. ×  2 2σ  n=1 2πσ " S # In this paper we have introduced a technique for parameter Y S  q estimation based on fitting a parametric model to a time se- where   ries that may be contaminated by temporally correlated noise γ 2 2 −γm + 2 with a 1/ f power spectral density. The essence of the tech- σW = σr 2 σw (42) − nique is to calculate the likelihood function in a wavelet ba- σ2 = σ22 γg(γ) + σ2 (43) sis. This is advantageous because a broad class of realistic S r w noise processes produce a nearly diagonal covariance matrix for some noise parameters σw > 0, σr > 0 and g(γ)= in the wavelet basis, and because fast methods for computing O(1) [e.g., g(1) 0.72]. ≈ 17

FIG. 13.— Results of parameter estimation for the simulated light curve of Fig. 12. Results for both the wavelet method (solid lines) and the white method (dashed lines) are compared. The upper left panel shows the posterior distribution for the midtransit time. The other panels show confidence contours (68.3% and 95.4%) of the joint posterior distribution of two parameters. The true parameter values are indicated by dotted lines. enough to be negligible. In fact, the magnitude of the cor- relations at different scales and times are dependent on the choice of wavelet basis and the spectral index γ describing the power spectral density of the correlated component of the noise. We have chosen for our experiments the Daubechies 4th-order wavelet basis which seems well-suited to the cases we considered. A perhaps more serious limitation is that the noise should be stationary. Real noise is often nonstationary. For example, photometric observations are noisier during pe- riods of poor weather, and even in good conditions there may be more noise at the beginning or end of the night when the target is observed through the largest airmass. It is possible that this limitation could be overcome with more elaborate noise models, or by analyzing the time series in separate seg- FIG. 14.— Isolating the correlated component. Plotted are the actual and ments; future work on these topics may be warranted. estimated 1/ f components of the noise in the simulated light curve plotted in Apart from the utility of the wavelet method, we draw the Fig. (12). The estimated 1/ f signal was found by applying the wavelet filter, following conclusions based on the numerical experiments of Eqn. (29), to the residuals. § 3. First, any analysis that ignores possible correlated errors (a “white” analysis in our terminology) is suspect, and any 2– The calculation entails the multiplication of N terms and has 3σ results from such an analysis should be regarded as provi- an overall time-complexity of O(N). With this prescription sional at best. As shown in §§ 4.1, 4.2, and 4.6, even data that for the likelihood function, the parameters may be optimized appear “good” on visual inspection and that are dominated by using any number of traditional algorithms. For example, the uncorrelated noise may give parameter errors that are under- likelihood may be used in the jump-transition probability ina estimated by a factor of 2–3 in a white analysis. Second, using Monte Carlo Markov Chain analysis, as we have done in this any of the methods described in 4.4 (the wavelet method, the work. time-averaging method, or the residual-permutation method) Among the premises of this technique are that the corre- is preferable to ignoring correlated noise altogether. lations among the wavelet and scaling coefficients are small 18

Throughout this work our main application has been es- tate the detection of transits and the elimination of statistical timation of the parameters of a single time series or a few false positives. Popular techniques for dealing with correlated such time series, especially determining the midtransit times noise in large photometric databases are those of Tamuz et of transit light curves. One potentially important application al. (2005), Kovács et al. (2005), and Pont et al. (2006). A that we have not discussed is the detection of transits in a priority for future work is to compare these methods with a database of time-series photometry of many stars. Photomet- wavelet-based method, by experimenting with realistic survey ric surveys such as the ground-based HAT (Bakos et al. 2007) data. and SuperWASP (Pollacco et al. 2006), and space-based mis- sions such as Corot (Baglin et al. 2003) and Kepler (Borucki et al. 2003) produce tens to hundreds of thousands of time se- We are grateful to Frederic Pont and Eric Feigelson for very ries, spanning much longer intervals than the transit durations. detailed and constructive critiques of an early version of this It seems likely that the parameters of a noise model could be manuscript. We also thank Scott Gaudi and Jason Eastman very well constrained using these vast databases, and that the for helpful comments. This work was partly supported by the application of a wavelet-based whitening filter could facili- NASA Origins program (grant no. NNX09AB33G).

REFERENCES Agol, E., Steffen, J., Sari, R., & Clarkson, W. 2005, MNRAS, 359, 567 Holman, M. J., & Murray, N. W. 2005, Science, 307, 1288 Alonso, R., Barbieri, M., Rabus, M., Deeg, H. J., Belmonte, J. A., & Holman, M. J., et al. 2006, ApJ, 652, 1715 Almenara, J. M. 2008, A&A, 487, L5 Jenkins, J. M., Caldwell, D. A., & Borucki, W. J. 2002, ApJ, 564, 495 Baglin, A. and the COROT team 2003, Advances in Space Research, 31, 345 Johnson, J. A., Winn, J. N., Cabrera, N. E., & Carter, J. A. 2009, ApJ, 692, Bakos, G. Á., et al. 2006, ApJ, 650, 1160 L100 Bakos, G. Á., et al. 2007, ApJ, 656, 552 Kipping, D. M. 2009, MNRAS, 392, 181 Bean, J. L., et al. 2008, A&A, 486, 1039 Koen, C., & Lombard, F. 1993, MNRAS, 263, 287 Beran, J. 1994, Statistics for Long-Memory Processes (London: Chapman & Konig, M., & Timmer, J. 1997, A&AS, 124, 589 Hall) Kovács, G., Bakos, G., & Noyes, R. W. 2005, MNRAS, 356, 557 Bevington, P. R., & Robinson, D. K. 2003, Data reduction and error analysis Mallat, S. G. 1989, IEEE Transactions on Pattern Analysis and Machine for the physical sciences, 3rd ed. (Boston, MA: McGraw-Hill) Intelligence, 11, 674 Borucki, W. J., et al. 2003, Proc. SPIE, 4854, 129 Mallat, S. A Wavelet Tour of Signal Processing, London:AP Professional, Bouchy, F., Pont, F., Melo, C., Santos, N. C., Mayor, M., Queloz, D., & 1997 Udry, S. 2005, A&A, 431, 1105 Mandel, K., & Agol, E. 2002, ApJ, 580, L171 Box, G. E. P., & Jenkins, G. M. 1976, Holden-Day Series in Time Series Percival D.B., & A.T. Walden. Spectral Analysis for Physical Applications: Analysis, Revised ed., San Francisco: Holden-Day, 1976, Multitaper and Conventional Univariate Techniques. Cambridge: Bracewell, R. The Fourier Transform and Its Applications. McGraw-Hill Cambridge University Press, 1993 Electrical and Electronic Engineering Series, Terman, F., Ed. New York: Pollacco, D. L., et al. 2006, PASP, 118, 1407 McGraw-Hill, 1965, pg. 115 Pont, F., Zucker, S., & Queloz, D. 2006, MNRAS, 373, 231 Burke, C. J., et al. 2007, ApJ, 671, 2115 Press, W. H. 1978, Comments on Astrophysics, 7, 103 Butler, R. P., Vogt, S. S., Marcy, G. W., Fischer, D. A., Wright, J. T., Henry, Press, William H., Teukolsky, Saul A., Vetterling, William T., & Flannery, G. W., Laughlin, G., & Lissauer, J. J. 2004, ApJ, 617, 580 Brian P. 2007, Numerical Recipes: The Art of Scientific Computing, 3rd Carter, J. A., Yee, J. C., Eastman, J., Gaudi, B. S., & Winn, J. N. 2008, ApJ, ed. (New York: Cambridge University Press) 689, 499 Ribas, I., Font-Ribera, A., & Beaulieu, J.-P. 2008, ApJ, 677, L59 Claret, A. 2004, A&A, 428, 1001 Southworth, J. 2008, MNRAS, 386, 1644 Collier Cameron, A., et al. 2007, MNRAS, 380, 1230 Tamuz, O., Mazeh, T., & Zucker, S. 2005, MNRAS, 356, 1466 Coughlin, J. L., Stringfellow, G. S., Becker, A. C., López-Morales, M., Teolis, A. Computational Signal Processing with Wavelets. Mezzalira, F., & Krajci, T. 2008, ApJ, 689, L149 Boston:Birkhäuser, 1998 Daubechies, I. 1988, Communications on Pure and Applied Mathematics, Timmer, J., Schwarz, U., Voss, H. U., Wardinski, I., Belloni, T., Hasinger, 41, 7, 909 G., van der Klis, M., & Kurths, J. 2000, Phys. Rev. E, 61, 1342 Fadili, M.J. & Bullmore, E.T. 2002, Neuroimage, 15, 217 Udalski, A., Szymanski, M. K., Kubiak, M., Pietrzynski, G., Soszynski, I., Gibson, N. P., et al. 2008, A&A, 492, 603 Zebrun, K., Szewczyk, O., & Wyrzykowski, L. 2004, Acta Astronomica, Gillon, M., Pont, F., Moutou, C., Bouchy, F., Courbin, F., Sohy, S., & 54, 313 Magain, P. 2006, A&A, 459, 249 Winn, J. N., et al. 2007, AJ, 133, 1828 Gillon, M., et al. 2007, A&A, 472, L13 Winn, J. N., et al. 2008, ApJ, 683, 1076 Gillon, M., et al. 2009, A&A, 496, 259 Winn, J. N., Holman, M. J., Carter, J. A., Torres, G., Osip, D. J., & Beatty, T. Giménez, A. 2007, A&A, 474, 1049 2009, AJ, 137, 3826 Gould, A. 2003, ArXiv Astrophysics e-prints, arXiv:astro-ph/0310577 Wornell, G. Signal Processing with Fractals: A Wavelet-Based Approach. Gregory, P. C. 2005, Bayesian Logical Data Analysis for the Physical Prentice Hall Signal Processing Series, Oppenheim, A., Ed. Upper Saddle Sciences: A Comparative Approach with Mathematica Support River, NJ:Prentice Hall Press, 1996 (Cambridge Univ. Press, UK). Haar, A., Zur Theorie der Orthogonalen Funktionensysteme., Math. Annal., Vol. 69, pp. 331-371, 1910