# On a Novel Approach to Correcting Temperature Dependencies in Magnetic Observatory Data
## 4 Temperature Correction of Data
### Data for November 2021  
The _G-mean(G)_ plot for November 2021 is shown in Figure 10. It is characterized by a bell-shaped form at the beginning of the month during a magnetic storm. The graph then tends to decrease towards the end of the month, which correlates well with temperature. Typically, such a constant trend is eliminated by the standard application of a daily smoothed baseline. However, the graph \(G\), without the temperature correction shown earlier in Figure 4, demonstrated that the trend is not fully eliminated by the standard procedure, so a temperature correction at the end of the month is still desirable.  
Figure 10: Correlation and localization in November 2021. Notations are the same as in Figure 6.  
Figure 9: Plots \(G\) for June 2021 after correction. Notations are the same as in Figure 7.  
From the end of November, the \(a+bT\) graph went into a negative-value area, and by December 9, it rapidly returned to zero. Extending the November localization interval to this date, similar to that of May 2021, would result in a jump at the starting point of December's temperature correction. If one moved in the opposite direction, from December to November, the graph of \(a+bT\) somehow crossed zero during November. Thus, a more accurate removal of a downward slope of the \(G\)-\(mean(G)\) graph at the November-December transition would be provided while correcting the December data over the localization interval extended to the left.  
Thus, the temperature correction in November was just about the elimination of the bell-shaped segment of the \(G\)-\(mean(G)\) graph at the start of the month. For that, we first specified the reference interval in the spt.txt file for November 2021 as  
\"2021-11-01 11:15:00; 2021-11-08 12:00:00\".  
In Figure 10, this reference interval was shown as a red segment; its choice corresponded to the best approximation of the \(G\)-\(mean(G)\) bell shape by the correlated temperature graph \(a+bT\). Afterwards, we set in the spc.txt file the automatic mode and the approximate position of the boundaries of the localization interval, for example, by simply transferring the reference interval from the spt.txt file:  
\"a2021-11; 2021-11-01 11:15:00; 2021-11-08 12:00:00\".  
As a result of the algorithm execution, this string is converted into a string  
\"a2021-11; 2021-11-01 13:36:00; 2021-11-08 15:37:00; \(-\)2.1844; 0.1600\",  
which contains the defined exact localization interval and the correlation coefficients. In Figure 9, this interval was depicted, as in the previous examples, by a blue segment. In this case, its ends exactly coincided with the ends of the centrally located green segment, denoting the points of transition of the graph \(a+bT\) through 0 before and after the \"bell\" in the graph \(G\)-\(mean(G)\).  
The \(G\) plot for November 2021 after the temperature correction of the variation data is shown in blue in Figure 11. Due to the use of the former baseline values, the graph contains a clear artificial positive trend in the range of absolute measurements on 9 November. As before, its elimination was provided by recalculating the baseline values using the corrected variation data. The final graph \(G\) for November 2021 is shown in orange.  
Figure 11: Plots \(G\) for November 2021 after correction. Notations are the same as in Figure 7.