deepinsight.insights package¶
Module contents¶
-
deepinsight.insights.
save_data
(id, payload, content_type, label=None, project_id=None, encoding=None)¶ Saves data as a DeepInsight static insight that can be exposed on the dashboard
Parameters: - id (str) – Unique identifier of the insight within the project. If an insight with the same identifier already exists, it will be replaced
- payload – bytes-oriented data, or Base64 string
- content_type – the MIME type of the data in payload (example: text/html or image/png)
- label (str) – Optional display label for the insight. If None, the id will be used as label
- project_id (str) – Project id in which the insight must be saved. If None, the contextual (current) project is used
- encoding (str) – If the payload was a Base64 string, this must be “base64”. Else, this must be None
-
deepinsight.insights.
save_figure
(id, figure=None, label=None, project_id=None)¶ Saves a matplotlib or seaborn figure as a DeepInsight static insight that can be exposed on the dashboard
Parameters: - id (str) – Unique identifier of the insight within the project. If an insight with the same identifier already exists, it will be replaced
- figure – a matplotlib or seaborn figure object. If None, the latest processed figure will be used
- label (str) – Optional display label for the insight. If None, the id will be used as label
- project_id (str) – Project id in which the insight must be saved. If None, the contextual (current) project is used
-
deepinsight.insights.
save_bokeh
(id, bokeh_obj, label=None, project_id=None)¶ Saves a Bokeh object as a DeepInsight static insight that can be exposed on the dashboard A static HTML export of the provided Bokeh object is done
Parameters: - id (str) – Unique identifier of the insight within the project. If an insight with the same identifier already exists, it will be replaced
- bokeh_obj – a Bokeh object
- label (str) – Optional display label for the insight. If None, the id will be used as label
- project_id (str) – Project id in which the insight must be saved. If None, the contextual (current) project is used
-
deepinsight.insights.
save_plotly
(id, figure, label=None, project_id=None)¶ Saves a Plot.ly figure as a DeepInsight static insight that can be exposed on the dashboard A static HTML export of the provided Plot.ly object is done
Parameters: - id (str) – Unique identifier of the insight within the project. If an insight with the same identifier already exists, it will be replaced
- figure – a Plot.ly figure
- label (str) – Optional display label for the insight. If None, the id will be used as label
- project_id (str) – Project id in which the insight must be saved. If None, the contextual (current) project is used
-
deepinsight.insights.
save_ggplot
(id, gg, label=None, width=None, height=None, dpi=None, project_id=None)¶ Saves a ggplot object as a DeepInsight static insight that can be exposed on the dashboard
Parameters: - id (str) – Unique identifier of the insight within the project. If an insight with the same identifier already exists, it will be replaced
- gg – a ggplot object
- label (str) – Optional display label for the insight. If None, the id will be used as label
- width (int) – Width of the image export
- height (int) – Height of the image export
- dpi (int) – Resolution in dots per inch of the image export
- project_id (str) – Project id in which the insight must be saved. If None, the contextual (current) project is used
-
deepinsight.insights.
get_insight
(insightid, project_id=None)¶
-
deepinsight.insights.
update_insight
(insight)¶