def plot_rolling_volatility(returns, factor_returns=None,<EOL>rolling_window=APPROX_BDAYS_PER_MONTH * <NUM_LIT:6>,<EOL>legend_loc='<STR_LIT>', ax=None, **kwargs):
if ax is None:<EOL><INDENT>ax = plt.gca()<EOL><DEDENT>y_axis_formatter = FuncFormatter(utils.two_dec_places)<EOL>ax.yaxis.set_major_formatter(FuncFormatter(y_axis_formatter))<EOL>rolling_vol_ts = timeseries.rolling_volatility(<EOL>returns, rolling_window)<EOL>rolling_vol_ts.plot(alpha=<NUM_LIT>, lw=<NUM_LIT:3>, color='<STR_LIT>', ax=ax,<EOL>**kwargs)<EOL>if factor_returns is not None:<EOL><INDENT>rolling_vol_ts_factor = timeseries.rolling_volatility(<EOL>factor_returns, rolling_window)<EOL>rolling_vol_ts_factor.plot(alpha=<NUM_LIT>, lw=<NUM_LIT:3>, color='<STR_LIT>', ax=ax,<EOL>**kwargs)<EOL><DEDENT>ax.set_title('<STR_LIT>')<EOL>ax.axhline(<EOL>rolling_vol_ts.mean(),<EOL>color='<STR_LIT>',<EOL>linestyle='<STR_LIT>',<EOL>lw=<NUM_LIT:3>)<EOL>ax.axhline(<NUM_LIT:0.0>, color='<STR_LIT>', linestyle='<STR_LIT:->', lw=<NUM_LIT:2>)<EOL>ax.set_ylabel('<STR_LIT>')<EOL>ax.set_xlabel('<STR_LIT>')<EOL>if factor_returns is None:<EOL><INDENT>ax.legend(['<STR_LIT>', '<STR_LIT>'],<EOL>loc=legend_loc, frameon=True, framealpha=<NUM_LIT:0.5>)<EOL><DEDENT>else:<EOL><INDENT>ax.legend(['<STR_LIT>', '<STR_LIT>', '<STR_LIT>'],<EOL>loc=legend_loc, frameon=True, framealpha=<NUM_LIT:0.5>)<EOL><DEDENT>return ax<EOL>
Plots the rolling volatility versus date.

Parameters
----------
returns : pd.Series
    Daily returns of the strategy, noncumulative.
     - See full explanation in tears.create_full_tear_sheet.
factor_returns : pd.Series, optional
    Daily noncumulative returns of the benchmark factor to which betas are
    computed. Usually a benchmark such as market returns.
     - This is in the same style as returns.
rolling_window : int, optional
    The days window over which to compute the volatility.
legend_loc : matplotlib.loc, optional
    The location of the legend on the plot.
ax : matplotlib.Axes, optional
    Axes upon which to plot.
**kwargs, optional
    Passed to plotting function.

Returns
-------
ax : matplotlib.Axes
    The axes that were plotted on.