# 7.5.3 Processing steps

The main processing steps of the SVD-Solar-Like-SOS-Rotational-Modulation pipeline are the following:

• selection of the input sources

• segmentation of the photometric time-series

• estimate of the linear correlation degree between gmag and $G_{\mathrm{BP}}-G_{\mathrm{RP}}$ observations in each time-series segment

• search for outliers in time-series segments

• search for a periodic signal in each time-series segment

• modelling of the $G$ time-series

• estimate of a magnetic activity index in each time-series segment

• estimate of the stellar rotation period.

The first four tasks are performed by the SVD package whereas the others are performed by the SOS package. The selection of the input candidates is performed according the criteria outlines in Section 7.5.2. The segmentation of photometric time-serie is required because the typical lifetime of spots and faculae is of the order of several months (see e.g. Lanza et al. 2003; Messina et al. 2003, and reference therein). A detailed description of the adopted segmentation algorithm can be found in Lanzafame et al. (in preparation). A well defined linear correlation between colour and magnitude measurements is expected for variability due rotational modulation in solar-like stars (see e.g. Messina et al. 2006). The SVD-Solar-Like package estimates the Pearson Correlation Coefficient $r$ between $G$ and $G_{\mathrm{BP}}-G_{\mathrm{RP}}$ observations in each time-series segment. This index can be regarded as an indicator of variability due to rotational modulation. The closer $r$ is to $\pm 1$ the higher the probability that rotational modulation is occurring. The SVD-Solar-Like package performs also a robust linear regression between $G$ and $G_{\mathrm{BP}}-G_{\mathrm{RP}}$ observations. The robust regression procedure permits also to identify possible outliers i.e. points whose location in the $G$ vs. $G_{\mathrm{BP}}-G_{\mathrm{RP}}$ scatter plot, is significantly distant from the straight-line best-fitting the data. The identification of photometric outliers is also performed by searching for the observations satisfying the condition

 $(G_{\rm BP}-G_{\rm RP})_{i}<\overline{G_{\rm BP}-G_{\rm RP}}-5\sigma_{G_{\rm BP% }-G_{\rm RP}}$ (7.2)

The points identified as outliers can be regarded as candidate flare-events. The SOS-Rotational-Modulation package performs a period search in each time-series segment by computing the generalised Lomb-Scargle periodogram as implemented by Zechmeister and Kürster (2009). The period with the highest power in the periodogram is selected by the pipeline and a False Alarm Probability (FAP) is associated with it. The formulation used to compute the FAP is that prescribed by Baluev (2008). A period is flagged as valid if the associated FAP is less then 0.05. If a significant period is detected in a given segment, the pipeline performs also a data modelling and fits the time-series segment to the function:

 $G(t)=A+B\sin\left(\frac{2\pi t}{P}\right)+C\cos\left(\frac{2\pi t}{P}\right)$ (7.3)

where t is the observation time referred to the reference epoch $t_{start}$ that is the time at which starts the segment and $P$ is the period detected in the segment. The SOS-RotationalModulation package estimates the rotation period of a solar-like candidate by analysing the distribution of the periods recovered in the different time-series segments. The mode of the distribution is taken as best estimate of the stellar rotation period. The amplitude of rotational modulation can be regarded as an index of the stellar magnetic activity and is widely used to study solar-like activity cycles (see e.g. Rodonò et al. 2000; Ferreira Lopes et al. 2015; Lehtinen et al. 2016). For a given we computed an estimate of this Activity Index (AI) by means of the equation:

 $AI=G_{95th}-G_{5th}$ (7.4)

where $G_{95th}$ and $G_{5th}$ are the 95-th and 5-th percentiles of the $G$ magnitudes measured in the segment. Note that an alternative estimate of the amplitude associate with rotational modulation can be inferred from the fit coefficients of Equation 7.3 through the relationship:

 $A_{fit}=2\sqrt{B^{2}+C^{2}}$ (7.5)

A more detailed description of the reduction pipeline can be found in Lanzafame et al. (in preparation).