The solar radiation is one of the important factors controlling the formation of $O_3$, and thereby impacting the levels of various secondary species in the atmosphere.
However, in the campaign of ambient $PM_{2.5}$ sampling, I don't have the instrument to acquire the actual solar radiation data. Since the solar radiation can be calculated mainly by the altitude degree of the sun, I turned to find a way to calculate the ideal values in clean sky condition.
I found that pysolar is a potential tool to tackle this kind of issue. By simply defining the location(Lon, Lat), and the date time, the solar radiation in the unit of $W/m^2$ can be generated.
However, the output result here seems to be strange.
Here is an example using Python 3.4:
# Noted that the package can only be implemented in Python 3.4 environment
from pysolar.solar import *
import datetime
# define the location (Beijing, China)
lat, lon = 39.9075, 116.39723
# generate the time series dataset of the solar radiation
start = datetime.datetime(2018, 1, 1, 8, 0, 0, 0, tzinfo=datetime.timezone.utc)
solar_data = []
for i in range(0,24*90,1): # 24 hours x 90 days
date = start + pd.to_timedelta(1,'H')
altitude_deg = get_altitude(lat, lon, date)
solar_data.append(radiation.get_radiation_direct(date, altitude_deg))
solar_ = pd.Dataframe([])
solar_['value] = solar_data
# Plotting
## Before plotting, I found there are a lot of extreme values with the radiation larger than 10e5. I don't know the reasons why they came up, and how to delete those data by conditions.
solar_.loc[solar_.value>5000, 'value'] = np.nan
plt.plot(solar_.value)
The result seems to be incorrect. In my opinion, the solar radiation should present a clear diurnal pattern with seasonal heterogeneity.
How to explain the bizarre results? Or is there any better solution for the solar radiation data if the monitoring equipment is unavailable.
Any comments or suggestions would be appreciated.
PS: I added the result of altitude degree the same period to response the comment of BarocliniCplusplus