Skip to content

Commit d71b198

Browse files
committed
add readme
1 parent 47f5810 commit d71b198

1 file changed

Lines changed: 27 additions & 22 deletions

File tree

‎README.md‎

Lines changed: 27 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,56 @@
1-
# RAWGraphs Custom Chart template
1+
# Ridgeline Plot for RAWGraphs
22

3-
This template allows you to create and utilize your own custom chart within the RAWGraphs interface. Custom charts are stored locally on your machine but can be shared with others by downloading the `.rawgraphs` project file and sending it to them.
3+
This custom chart is intended to be used inside the [RAWGraphs app](https://app.rawgraphs.io/).
44

5-
Within a custom chart, you have the ability to define the chart variables and visual options that you wish to expose. By defining a JavaScript function and utilizing these inputs, you can generate a chart. Charts can be generated as SVG, canvas, or HTML nodes.
5+
## What is a Ridgeline Plot
66

7-
When you load the custom chart in RAWGraphs, the necessary interface components will be automatically generated based on your chart specifications.
7+
A ridgeline plot (also known as a joy plot) shows the distribution or temporal evolution of several groups over a shared continuous axis. Each group is rendered as a filled area with an optional stroke, stacked vertically with a configurable amount of overlap. The overlapping layout makes it easy to compare many series at once while preserving the individual shape of each distribution.
88

9-
Outlined below are the fundamental operations you can perform to initiate a new project.
9+
The chart is inspired by the [D3 Ridgeline Plot](https://observablehq.com/@d3/ridgeline-plot) by Mike Bostock.
1010

11-
For more detailed instructions on building custom charts, read the following documentation:
11+
## Installation
1212

13-
* [Create your first chart](docs/add-a-new-chart.md)
14-
* [Good practices and conventions](docs/good-practices.md)
15-
* [RAWgraphs core library technical documentation](https://rawgraphs.github.io/rawgraphs-core/docs/)
13+
- Download the latest release asset (`index.umd.js`) from the side panel on this page or from the [Releases](../../releases/latest) tab.
14+
- In [RAWGraphs](https://app.rawgraphs.io/) load a dataset. You can try the [sample traffic file](example/datasets/traffic_weekly.csv).
15+
- In section `2. Choose a chart`, scroll down and click `Load your chart`.
16+
- Select the `Load from file` tab, then drag and drop the downloaded file.
17+
- Click `Load your chart`, acknowledge the pop-up about external code, and continue.
18+
- The Ridgeline Plot will now be available in your chart list.
1619

17-
## Install
20+
## Contribute
1821

19-
To create a custom chart you'll need [node.js](https://nodejs.org/en) installed on your computer.
22+
If you'd like to contribute, follow the RAWGraphs [custom template guide](https://github.com/rawgraphs/custom-rawcharts-template).
2023

21-
In terminal navigate the folder in wich you cloned this template and run:
24+
## Edit the code
25+
26+
### Install dependencies
2227

2328
```sh
2429
npm install
2530
```
2631

27-
## Run Sandbox
28-
29-
While developing your custom chart, you can see it in realtime by running the sandbox environment.
32+
### Run Sandbox
3033

31-
In terminal navigate the folder in wich you cloned this template and run:
34+
Modify the chart locally with live reload.
3235

3336
```sh
3437
npm run sandbox
3538
```
3639

37-
You can find your charts at [http://localhost:9000](http://localhost:9000)
38-
39-
## Build
40+
Open [http://localhost:9000](http://localhost:9000) to view the sandbox.
4041

41-
When you are satisfied with your project, you can build the js bundle to be used in the RAWGraphs interface.
42+
### Build
4243

43-
In terminal navigate the folder in wich you cloned this template and run:
44+
Create the bundle to load in RAWGraphs.
4445

4546
```sh
4647
npm run build
4748
```
4849

49-
This will generate a folder named `lib` in which you will find three files.
50+
The `lib/index.umd.js` file is the bundle you can load into RAWGraphs.
51+
52+
## Credits
53+
54+
Original chart concept by [Mike Bostock](https://observablehq.com/@d3/ridgeline-plot).
5055

5156
The one named `index.umd.js` is the bundle that can be loaded by RAWGraphs. You cna rename it as you prefer.

0 commit comments

Comments
 (0)