plot_neural_reconstruction_traces¶
- behavenet.plotting.decoder_utils.plot_neural_reconstruction_traces(traces_ae, traces_neural, save_file=None, xtick_locs=None, frame_rate=None, format='png', scale=0.5, max_traces=8, add_r2=True, add_legend=True, colored_predictions=True, title=None)[source]¶
Plot ae latents and their neural reconstructions.
- Parameters:
traces_ae (
np.ndarray) – shape (n_frames, n_latents)traces_neural (
np.ndarray) – shape (n_frames, n_latents)save_file (
str, optional) – full save file (path and filename)xtick_locs (
array-like, optional) – tick locations in units of binsframe_rate (
float, optional) – frame rate of behavorial video; to properly relabel xticksformat (
str, optional) – any accepted matplotlib save format, e.g. ‘png’ | ‘pdf’ | ‘jpeg’scale (
int, optional) – scale magnitude of tracesmax_traces (
int, optional) – maximum number of traces to plot, for easier visualizationadd_r2 (
bool, optional) – print R2 value on plotadd_legend (
bool, optional) – print legend on plotcolored_predictions (
bool, optional) – color predictions using default seaborn colormap; else predictions are blacktitle (
str, optional) – add title to plot
- Returns:
matplotlib figure handle
- Return type:
matplotlib.figure.Figure