ranaroussi / quantstats

Missing module/function docstring PY-D0003
Documentation
Minor
40 occurrences in this check
Docstring missing for _embed_figure
1616        iDisplay(iHTML(jscode))
1617
1618
1619def _embed_figure(figfiles, figfmt):1620    if isinstance(figfiles, list):
1621        embed_string = "\n"
1622        for figfile in figfiles:
Docstring missing for _open_html
1601        iDisplay(iHTML(jscode.replace("{{filename}}", filename)))
1602
1603
1604def _open_html(html):1605    jscode = _regex.sub(
1606        " +",
1607        " ",
Docstring missing for _download_html
1581    return obj
1582
1583
1584def _download_html(html, filename="quantstats-tearsheet.html"):1585    jscode = _regex.sub(
1586        " +",
1587        " ",
Docstring missing for _html_table
1567    return dd_stats.T
1568
1569
1570def _html_table(obj, showindex="default"):1571    obj = _tabulate(
1572        obj, headers="keys", tablefmt="html", floatfmt=".2f", showindex=showindex
1573    )
Docstring missing for _calc_dd
1483            )
1484
1485
1486def _calc_dd(df, display=True, as_pct=False):1487    dd = _stats.to_drawdown_series(df)
1488    dd_info = _stats.drawdown_details(dd)
1489
Docstring missing for plots
1202    return metrics
1203
1204
1205def plots(1206    returns,
1207    benchmark=None,
1208    grayscale=False,
Docstring missing for metrics
 720    )
 721
 722
 723def metrics( 724    returns,
 725    benchmark=None,
 726    rf=0.0,
Docstring missing for basic
 640    )
 641
 642
 643def basic( 644    returns,
 645    benchmark=None,
 646    rf=0.0,
Docstring missing for full
 489        f.write(tpl)
 490
 491
 492def full( 493    returns,
 494    benchmark=None,
 495    rf=0.0,
Docstring missing for html
  51    return returns, benchmark
  52
  53
  54def html(  55    returns,
  56    benchmark=None,
  57    rf=0.0,
Docstring missing for _match_dates
  40    return periods_per_year, half_year
  41
  42
  43def _match_dates(returns, benchmark):  44    if isinstance(returns, _pd.DataFrame):
  45        loc = max(returns[returns.columns[0]].ne(0).idxmax(), benchmark.ne(0).idxmax())
  46    else:
Docstring missing for _get_trading_periods
  35    from IPython.core.display import display as iDisplay, HTML as iHTML
  36
  37
  38def _get_trading_periods(periods_per_year=252):  39    half_year = _ceil(periods_per_year / 2)
  40    return periods_per_year, half_year
  41
Docstring missing for monthly_returns
1065    return None
1066
1067
1068def monthly_returns(1069    returns,
1070    annot_size=10,
1071    figsize=(10, 5),
Docstring missing for monthly_heatmap
 936        return fig
 937
 938
 939def monthly_heatmap( 940    returns,
 941    benchmark=None,
 942    annot_size=10,
Docstring missing for rolling_sortino
 892        return fig
 893
 894
 895def rolling_sortino( 896    returns,
 897    benchmark=None,
 898    rf=0.0,
Docstring missing for rolling_sharpe
 842        return fig
 843
 844
 845def rolling_sharpe( 846    returns,
 847    benchmark=None,
 848    rf=0.0,
Docstring missing for rolling_volatility
 799        return fig
 800
 801
 802def rolling_volatility( 803    returns,
 804    benchmark=None,
 805    period=126,
Docstring missing for rolling_beta
 755        return fig
 756
 757
 758def rolling_beta( 759    returns,
 760    benchmark,
 761    window1=126,
Docstring missing for drawdowns_periods
 717        return fig
 718
 719
 720def drawdowns_periods( 721    returns,
 722    periods=5,
 723    lw=1.5,
Docstring missing for drawdown
 674    )
 675
 676
 677def drawdown( 678    returns,
 679    grayscale=False,
 680    figsize=(10, 5),
Docstring missing for histogram
 627        return fig
 628
 629
 630def histogram( 631    returns,
 632    benchmark=None,
 633    resample="M",
Docstring missing for distribution
 595        return fig
 596
 597
 598def distribution( 599    returns,
 600    fontname="Arial",
 601    grayscale=False,
Docstring missing for yearly_returns
 533        return fig
 534
 535
 536def yearly_returns( 537    returns,
 538    benchmark=None,
 539    fontname="Arial",
Docstring missing for daily_returns
 488        return fig
 489
 490
 491def daily_returns( 492    returns,
 493    benchmark,
 494    grayscale=False,
Docstring missing for log_returns
 433        return fig
 434
 435
 436def log_returns( 437    returns,
 438    benchmark=None,
 439    grayscale=False,