Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ version = "1.0.1-DEV"
[deps]
CSVFiles = "5d742f6a-9f54-50ce-8119-2520741973ca"
Classes = "1a9c1350-211b-5766-99cd-4544d885a0d1"
Compose = "a81c6b42-2e10-5240-aca2-a61377ecd94b"
DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
Expand Down Expand Up @@ -38,7 +37,6 @@ VegaLite = "112f6efa-9a02-5b7d-90c0-432ed331239a"
[compat]
CSVFiles = "0.16, 1.0"
Classes = "1.2"
Compose = "0.7, 0.8, 0.9"
DataFrames = "0.19.1, 0.20, 0.21"
DataStructures = "0.17"
Distributions = "0.21, 0.22, 0.23"
Expand Down
Binary file removed docs/src/figs/plot_comp_graph_example.png
Binary file not shown.
12 changes: 2 additions & 10 deletions docs/src/howto/howto_2.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,9 @@ getdataframe(m, :Component1=>:Var1, :Component2=>:Var2) # request variables from

## Plotting and the Explorer UI

Mimi provides support for plotting using [VegaLite](https://github.com/vega/vega-lite) and [VegaLite.jl](https://github.com/fredo-dedup/VegaLite.jl) within the Mimi Explorer UI and `Mimi.plot` function, and the [LightGraphs](https://github.com/JuliaGraphs/LightGraphs.jl) and [MetaGraphs](https://github.com/JuliaGraphs/MetaGraphs.jl) for the `plot_comp_graph` function described below.
Mimi provides support for plotting using [VegaLite](https://github.com/vega/vega-lite) and [VegaLite.jl](https://github.com/fredo-dedup/VegaLite.jl).

In order to view a DAG representing the component ordering and relationships, use the `plot_comp_graph` function to view a plot and optionally save it to a file.

```julia
run(m)
plot_comp_graph(m; filename = "MyFilePath.png")
```
![Plot Component Graph Example](../figs/plot_comp_graph_example.png)

Other plotting support is provided by the **Explorer UI**, rooted in `VegaLite`. The `explore` function allows the user to view and explore the variables and parameters of a model run. The explorer can be used in two primary ways.
Plotting support is provided by the **Explorer UI**, rooted in `VegaLite`. The `explore` function allows the user to view and explore the variables and parameters of a model run. The explorer can be used in two primary ways.

In order to invoke the explorer UI and explore all of the variables and parameters in a model, simply call the function `explore` with the model run as the required argument, and a window title as an optional keyword argument, as shown below. This will produce a new browser window containing a selectable list of parameters and variables, organized by component, each of which produces a graphic. The exception here being that if the parameter or variable is a single scalar value, the value will appear alongside the name in the left-hand list.

Expand Down
1 change: 0 additions & 1 deletion docs/src/ref/ref_API.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ is_last
modeldef
parameter_names
parameter_dimensions
plot_comp_graph
replace!
set_dimension!
set_leftover_params!
Expand Down
11 changes: 1 addition & 10 deletions docs/src/tutorials/tutorial_2.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ getdataframe(m, :socioeconomic=>:income)[1:16,:] # results for all regions in fi

After running the FUND model, you may also explore the results using plots and graphs.

Mimi provides support for plotting using [VegaLite](https://github.com/vega/vega-lite) and [VegaLite.jl](https://github.com/fredo-dedup/VegaLite.jl) within the Mimi Explorer UI, and the [LightGraphs](https://github.com/JuliaGraphs/LightGraphs.jl) and [MetaGraphs](https://github.com/JuliaGraphs/MetaGraphs.jl) for the [`plot_comp_graph`](@ref) function.
Mimi provides support for plotting using [VegaLite](https://github.com/vega/vega-lite) and [VegaLite.jl](https://github.com/fredo-dedup/VegaLite.jl) within the Mimi Explorer UI.

#### Explore

Expand All @@ -147,15 +147,6 @@ More specifically for our tutorial use of FUND, try:
p = Mimi.plot(m, :socioeconomic, :income)
save("MyFilePath.svg", p)
```

#### Component Graph

In order to view a DAG representing the component ordering and relationships, use the [`plot_comp_graph`](@ref) function to view a plot and optionally save it to a file. This function returns a plot object displayed in the viewer and showing a graph with components as nodes and component connections as edges.

```julia
plot_comp_graph(m, "MyFilePath.png")
```

----

You're done! Now feel free to move on to the next tutorial, which will go into depth on how to **modify** an existing model such as FUND.
3 changes: 0 additions & 3 deletions src/Mimi.jl
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ export
# parameters,
parameter_dimensions,
parameter_names,
plot_comp_graph,
replace_comp!,
set_dimension!,
set_leftover_params!,
Expand Down Expand Up @@ -67,7 +66,6 @@ include("core/references.jl")
include("core/time.jl")
include("core/time_arrays.jl")
include("core/model.jl")
include("core/order.jl")
include("core/paths.jl")
include("core/show.jl")

Expand All @@ -77,7 +75,6 @@ include("utils/getdataframe.jl")
include("utils/graph.jl")
include("utils/lint_helper.jl")
include("utils/misc.jl")
include("utils/plotting.jl")

# Load built-in components
include("components/adder.jl")
Expand Down
3 changes: 0 additions & 3 deletions src/core/connections.jl
Original file line number Diff line number Diff line change
Expand Up @@ -632,8 +632,5 @@ function add_connector_comps!(obj::AbstractCompositeComponentDef)
end
end

# Save the sorted component order for processing
# obj.sorted_comps = _topological_sort(obj)

return nothing
end
64 changes: 0 additions & 64 deletions src/core/order.jl

This file was deleted.

36 changes: 0 additions & 36 deletions src/utils/plotting.jl

This file was deleted.

3 changes: 0 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,6 @@ Electron.prep_test_env()
@info("test_explorer_compositecomp.jl")
@time include("test_explorer_compositecomp.jl")

@info("test_plotting.jl")
@time include("test_plotting.jl")

@info("mcs/runtests.jl")
@time include("mcs/runtests.jl")

Expand Down
43 changes: 0 additions & 43 deletions test/test_plotting.jl

This file was deleted.