Here is my problem: I have a pandas DataFrame with 15 minutes acquisition and a timestamp of 0.05 s.
The column time is a datetime format and following this format :(YYYY-mm-dd HH:MM:SS %.f) with %.f is microsecond.
I want to have a plot of the data and I tried this code :
plt.plot(WaveLab_df['Time'],WaveLab_df['Mecanical_Power_Starboard'],'g--')
plt.xlabel('Time')
plt.ylabel('Power (W)')
But I have this figure :
As you can see I have only 3 x axis points. What I would like is to have at least one each minute.
I tried also the following code in order to make my own x axis:
base=WaveLab_df.loc[0,'Time']
date_range=[base+dt.timedelta(minutes=x) for x in range(0,15,3)]
plt.plot(WaveLab_df['Time'],WaveLab_df['Mecanical_Power_Starboard'],'g--')
plt.xticks(date_range)
plt.xlabel('Time')
plt.ylabel('Power(W)')
But I obtained this figure: