def NR_plot(stream, NR_stream, detections, false_detections=False,<EOL>size=(<NUM_LIT>, <NUM_LIT:10>), **kwargs):
import matplotlib.pyplot as plt<EOL>fig, axes = plt.subplots(len(stream) + <NUM_LIT:1>, <NUM_LIT:1>, sharex=True, figsize=size)<EOL>if len(stream) > <NUM_LIT:1>:<EOL><INDENT>axes = axes.ravel()<EOL><DEDENT>else:<EOL><INDENT>return<EOL><DEDENT>mintime = stream.sort(['<STR_LIT>'])[<NUM_LIT:0>].stats.starttime<EOL>stream.sort(['<STR_LIT>', '<STR_LIT>', '<STR_LIT>'])<EOL>for i, tr in enumerate(stream):<EOL><INDENT>delay = tr.stats.starttime - mintime<EOL>delay *= tr.stats.sampling_rate<EOL>y = tr.data<EOL>x = [tr.stats.starttime.datetime + dt.timedelta(<EOL>seconds=s / tr.stats.sampling_rate) for s in range(len(y))]<EOL>x = mdates.date2num(x)<EOL>axes[i].plot(x, y, '<STR_LIT:k>', linewidth=<NUM_LIT>)<EOL>axes[i].set_ylabel('<STR_LIT:.>'.join([tr.stats.station, tr.stats.channel]),<EOL>rotation=<NUM_LIT:0>)<EOL>axes[i].yaxis.set_ticks([])<EOL>axes[i].set_xlim(x[<NUM_LIT:0>], x[-<NUM_LIT:1>])<EOL><DEDENT>tr = NR_stream[<NUM_LIT:0>]<EOL>delay = tr.stats.starttime - mintime<EOL>delay *= tr.stats.sampling_rate<EOL>y = tr.data<EOL>x = [tr.stats.starttime.datetime +<EOL>dt.timedelta(seconds=s / tr.stats.sampling_rate)<EOL>for s in range(len(y))]<EOL>x = mdates.date2num(x)<EOL>axes[-<NUM_LIT:1>].plot(x, y, '<STR_LIT:k>', linewidth=<NUM_LIT>)<EOL>axes[-<NUM_LIT:1>].set_ylabel('<STR_LIT:.>'.join([tr.stats.station, tr.stats.channel]),<EOL>rotation=<NUM_LIT:0>)<EOL>axes[-<NUM_LIT:1>].yaxis.set_ticks([])<EOL>axes[-<NUM_LIT:1>].set_xlabel('<STR_LIT>')<EOL>axes[-<NUM_LIT:1>].set_xlim(x[<NUM_LIT:0>], x[-<NUM_LIT:1>])<EOL>ymin, ymax = axes[-<NUM_LIT:1>].get_ylim()<EOL>if false_detections:<EOL><INDENT>for detection in false_detections:<EOL><INDENT>xd = mdates.date2num(detection)<EOL>axes[-<NUM_LIT:1>].plot((xd, xd), (ymin, ymax), '<STR_LIT>', linewidth=<NUM_LIT>,<EOL>alpha=<NUM_LIT:0.5>)<EOL><DEDENT><DEDENT>for detection in detections:<EOL><INDENT>xd = mdates.date2num(detection)<EOL>axes[-<NUM_LIT:1>].plot((xd, xd), (ymin, ymax), '<STR_LIT>', linewidth=<NUM_LIT>)<EOL><DEDENT>mins = mdates.MinuteLocator()<EOL>timedif = tr.stats.endtime.datetime - tr.stats.starttime.datetime<EOL>if timedif.total_seconds() >= <NUM_LIT> and timedif.total_seconds() <= <NUM_LIT>:<EOL><INDENT>hours = mdates.MinuteLocator(byminute=[<NUM_LIT:0>, <NUM_LIT:15>, <NUM_LIT:30>, <NUM_LIT>])<EOL><DEDENT>elif timedif.total_seconds() <= <NUM_LIT>:<EOL><INDENT>hours = mdates.MinuteLocator(byminute=range(<NUM_LIT:0>, <NUM_LIT>, <NUM_LIT:2>))<EOL><DEDENT>elif timedif.total_seconds > <NUM_LIT> and timedif.total_seconds() <= <NUM_LIT>:<EOL><INDENT>hours = mdates.HourLocator(byhour=range(<NUM_LIT:0>, <NUM_LIT>, <NUM_LIT:3>))<EOL><DEDENT>elif timedif.total_seconds() > <NUM_LIT>:<EOL><INDENT>hours = mdates.DayLocator()<EOL><DEDENT>else:<EOL><INDENT>hours = mdates.MinuteLocator(byminute=range(<NUM_LIT:0>, <NUM_LIT>, <NUM_LIT:5>))<EOL><DEDENT>hrFMT = mdates.DateFormatter('<STR_LIT>')<EOL>axes[-<NUM_LIT:1>].xaxis.set_major_locator(hours)<EOL>axes[-<NUM_LIT:1>].xaxis.set_major_formatter(hrFMT)<EOL>axes[-<NUM_LIT:1>].xaxis.set_minor_locator(mins)<EOL>plt.gcf().autofmt_xdate()<EOL>axes[-<NUM_LIT:1>].fmt_xdata = mdates.DateFormatter('<STR_LIT>')<EOL>plt.subplots_adjust(hspace=<NUM_LIT:0>)<EOL>fig = _finalise_figure(fig=fig, **kwargs)  <EOL>return fig<EOL>
Plot Network response alongside the stream used.

Highlights detection times in the network response.

:type stream: obspy.core.stream.Stream
:param stream: Stream to plot
:type NR_stream: obspy.core.stream.Stream
:param NR_stream: Stream for the network response
:type detections: list
:param detections: List of the detection time as :class:`datetime.datetime`
:type false_detections: list
:param false_detections:
    Either False (default) or list of false detection times
    (:class:`datetime.datetime`).
:type size: tuple
:param size: Size of figure, default is (18.5, 10)

:returns: :class:`matplotlib.figure.Figure`

.. Note::
    Called by :mod:`eqcorrscan.core.bright_lights`, not a general use
    plot (hence no example)