|
3 | 3 | plot_data(data, value_ranges, categorical_vars, continuous_vars, mapping_obs) |
4 | 4 | Plotting an interactive dashboard. |
5 | 5 |
|
6 | | - Arguments: |
7 | | -- `data::DataFrame` - the result of `effects(Dict(...), model) ` with columns: yhat, channel, dummy, time, eventname and unique columns for each formula term.. |
8 | | -- `value_ranges::Vector{Pair{Symbol}}` - value range for continuous variables, levels for categorical. |
9 | | -- `categorical_vars::Vector{Symbol}` - categorical terms. |
10 | | -- `continuous_vars::Vector{Symbol}` - continuous terms. |
11 | | -- `mapping::Dict{Symbol, Symbol}` - dictionary with dropdown menus and their default values. |
12 | | -
|
13 | | -Action: |
14 | | -- Create default palettes for colors, markers, line styles, and color styles for continuous values. |
15 | | -- Check that the terms are not empty. |
16 | | -- Plot the dashboard. |
17 | | -- Define line and scatter styles for the line plot. |
| 6 | + Arguments:\\ |
| 7 | +- `data::DataFrame` - the result of `effects(Dict(...), model) ` with columns: yhat, channel, dummy, time, eventname and unique columns for each formula term.\\ |
| 8 | +- `value_ranges::Vector{Pair{Symbol}}` - value range for continuous variables, levels for categorical.\\ |
| 9 | +- `categorical_vars::Vector{Symbol}` - categorical terms.\\ |
| 10 | +- `continuous_vars::Vector{Symbol}` - continuous terms.\\ |
| 11 | +- `mapping::Dict{Symbol, Symbol}` - dictionary with dropdown menus and their default values.\\ |
| 12 | +
|
| 13 | +Action:\\ |
| 14 | +- Create default palettes for colors, markers, line styles, and color styles for continuous values.\\ |
| 15 | +- Check that the terms are not empty.\\ |
| 16 | +- Plot the dashboard.\\ |
| 17 | +- Define line and scatter styles for the line plot.\\ |
18 | 18 | - Add line and scatter styles to the legend. |
19 | 19 |
|
20 | 20 | **Return Value:** `Makie.GridLayoutSpec`. |
@@ -141,16 +141,17 @@ end |
141 | 141 | define_scatter_line_style!(plots, data, vars, scatter_styles, line_styles, continuous_vars) |
142 | 142 | Define styling of lines and points (scatter). |
143 | 143 |
|
144 | | -- subset the data. |
145 | | -- select points and plot scatter. Define scatter style: markersize and color. |
146 | | -- plot lines and define line style: colormap, color range, color. |
| 144 | +Actions:\\ |
| 145 | +- subset the data.\\ |
| 146 | +- select points and plot scatter. Define scatter style: markersize and color.\\ |
| 147 | +- plot lines and define line style: colormap, color range, color.\\ |
147 | 148 |
|
148 | 149 | Arguments:\\ |
149 | 150 | - `plots::Vector{Makie.PlotSpec}` - an empty SpecApi list to push into parts of the layout.\\ |
150 | 151 | - `data::DataFrame` - a DataFrame with predicted values to be subsetted.\\ |
151 | 152 | - `vars::Dict{Any, Any}` contains the levels to be plotted.\\ |
152 | | -- `scatter_styles::Dict{Any, Any}` - define colors of scatter. |
153 | | -- `line_styles:: Dict{Symbol, Pair{Symbol, Tuple{Tuple{String, String}, Symbol}}}` - define line styles: colormap, color range, color. |
| 153 | +- `scatter_styles::Dict{Any, Any}` - define colors of scatter.\\ |
| 154 | +- `line_styles:: Dict{Symbol, Pair{Symbol, Tuple{Tuple{String, String}, Symbol}}}` - define line styles: colormap, color range, color.\\ |
154 | 155 | - `continuous_vars::Vector{Symbol}` - continuous terms. |
155 | 156 |
|
156 | 157 | **Return Value:** `Makie.GridLayoutSpec`. |
|
0 commit comments