Skip to content

Commit

Permalink
Fix tutorials
Browse files Browse the repository at this point in the history
  • Loading branch information
fealho committed Oct 25, 2023
1 parent 4e321a5 commit 39f7469
Show file tree
Hide file tree
Showing 5 changed files with 164,041 additions and 359 deletions.
11 changes: 8 additions & 3 deletions copulas/visualization.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,13 @@ def _generate_1d_plot(data, title, labels, colors):
title=title,
plot_bgcolor=PlotConfig.BACKGROUND_COLOR,
font={'size': PlotConfig.FONT_SIZE},
showlegend=True if labels[0] else False,
)

return fig


def hist_1d(data, title=None, label=None):
def dist_1d(data, title=None, label=None):
"""Plot the 1 dimensional data.
Args:
Expand All @@ -72,7 +73,7 @@ def hist_1d(data, title=None, label=None):
return _generate_1d_plot(
data=[data],
title=title,
labels=[label or 'Data'],
labels=[label],
colors=[PlotConfig.DATACEBO_DARK]
)

Expand Down Expand Up @@ -138,6 +139,7 @@ def _generate_scatter_2d_plot(data, columns, color_discrete_map, title):
title=title,
plot_bgcolor=PlotConfig.BACKGROUND_COLOR,
font={'size': PlotConfig.FONT_SIZE},
showlegend=False if len(color_discrete_map) == 1 else True,
)

return fig
Expand Down Expand Up @@ -233,13 +235,16 @@ def _generate_scatter_3d_plot(data, columns, color_discrete_map, title):
z=columns[2],
color='Data',
color_discrete_map=color_discrete_map,
symbol='Data'
symbol='Data',
)

fig.update_traces(marker={'size': 5})

fig.update_layout(
title=title,
plot_bgcolor=PlotConfig.BACKGROUND_COLOR,
font={'size': PlotConfig.FONT_SIZE},
showlegend=False if len(color_discrete_map) == 1 else True,
)

return fig
Expand Down
10,938 changes: 10,900 additions & 38 deletions tutorials/00_Quickstart.ipynb

Large diffs are not rendered by default.

77,540 changes: 77,422 additions & 118 deletions tutorials/01_Introduction_to_Copulas.ipynb

Large diffs are not rendered by default.

28,433 changes: 28,297 additions & 136 deletions tutorials/02_Univariate_Distributions.ipynb

Large diffs are not rendered by default.

47,478 changes: 47,414 additions & 64 deletions tutorials/03_Multivariate_Distributions.ipynb

Large diffs are not rendered by default.

0 comments on commit 39f7469

Please sign in to comment.