Skip to content

Commit

Permalink
v0.4.0 - Update readme to reflect new layout array syntax for panels …
Browse files Browse the repository at this point in the history
…+ data layers
  • Loading branch information
Frencil committed Jun 28, 2016
1 parent 6c28706 commit f6fc4b2
Showing 1 changed file with 16 additions and 12 deletions.
28 changes: 16 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,20 @@ A layout definition may look something like this:
var layout = {
width: 500,
height: 500,
panels: {
association: {
data_layers: {
association: {
panels: [
{
id: "association",
data_layers: [
{
id: "association",
type: "scatter",
fields: ["trait:position", "trait:pvalue"],
x_axis: { field: "trait:position" },
y_axis: { field: "trait:pvalue" }
}
}
]
}
}
]
};
```

Expand Down Expand Up @@ -86,18 +88,20 @@ A basic example may then look like this:
var layout = {
width: 500,
height: 500,
panels: {
association: {
data_layers: {
association: {
panels: [
{
id : "association",
data_layers: [
{
id: "association",
type: "scatter",
fields: ["trait:position", "trait:pvalue"],
x_axis: { field: "trait:position" },
y_axis: { field: "trait:pvalue" }
}
}
]
}
}
]
};
var plot = LocusZoom.populate("#plot", datasource, layout);
</script>
Expand Down

0 comments on commit f6fc4b2

Please sign in to comment.