src/proteingnn/util.py
def reg_corr_plot(pred: Iterable, y: Iterable, full_range: bool = False) -> plt.Figure:
    """Utility function get seaborn jointplot between prediction and target values.

    Args:
        pred: Predicted values from model.
        y: Target values.
        full_range: If false, restrict plotted data points to true value range.
    """
    df = pd.DataFrame(zip(pred, y), columns=['predicted value', 'true value'])
    if full_range:
        # noinspection PyArgumentList
        lim = (df.values.min(), df.values.max())
    else:
        lim = (df['true value'].min(), df['true value'].max())
    jg = sns.jointplot(data=df, x='predicted value', y='true value', xlim=lim, ylim=lim)
    return jg.fig
Utility function get seaborn jointplot between prediction and target values.

    Args:
        pred: Predicted values from model.
        y: Target values.
        full_range: If false, restrict plotted data points to true value range.
    
Utility function get seaborn jointplot between prediction and target values.
Utility function get seaborn jointplot between prediction and target values .
def reg_corr_plot(pred: Iterable, y: Iterable, full_range: bool = False) -> plt.Figure:
    df = pd.DataFrame(zip(pred, y), columns=['predicted value', 'true value'])
    if full_range:
        lim = (df.values.min(), df.values.max())
    else:
        lim = (df['true value'].min(), df['true value'].max())
    jg = sns.jointplot(data=df, x='predicted value', y='true value', xlim=lim, ylim=lim)
    return jg.fig
def reg_corr_plot ( pred : Iterable , y : Iterable , full_range : bool = False ) -> plt . Figure : df = pd . DataFrame ( zip ( pred , y ) , columns = [ 'predicted value' , 'true value' ] ) if full_range : lim = ( df . values . min ( ) , df . values . max ( ) ) else : lim = ( df [ 'true value' ] . min ( ) , df [ 'true value' ] . max ( ) ) jg = sns . jointplot ( data = df , x = 'predicted value' , y = 'true value' , xlim = lim , ylim = lim ) return jg . fig
Utility function get seaborn jointplot between prediction and target values.
Utility function get seaborn jointplot between prediction and target values .
"""Utility function get seaborn jointplot between prediction and target values.

    Args:
        pred: Predicted values from model.
        y: Target values.
        full_range: If false, restrict plotted data points to true value range.
    """ # noinspection PyArgumentList
pred
Iterable
Predicted values from model.
Predicted values from model .
y
Iterable
None
full_range
bool
If false, restrict plotted data points to true value range.
If false restrict plotted data points to true value range .