Python Pandas Group by date using datetime data
<p>I have a column <code>Date_Time</code> that I wish to groupby date time without creating a new column. Is this possible the current code I have does not work.</p>

<pre><code>df = pd.groupby(df,by=[df['Date_Time'].date()])
</code></pre>

<p>Credit to @jezrael for his setup dataframe</p>

<hr>

<p>You can set the index to be <code>'Date_Time'</code> and use <code>pd.TimeGrouper</code></p>

<pre><code>df.set_index('Date_Time').groupby(pd.TimeGrouper('D')).mean().dropna()
</code></pre>

<p><a href="http://i.stack.imgur.com/JpCfM.png" rel="nofollow"><img src="http://i.stack.imgur.com/JpCfM.png" alt="enter image description here"></a></p>

python date datetime pandas group-by