Skip to content

Commit 733c07c

Browse files
committed
update README
1 parent fdec373 commit 733c07c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -727,7 +727,7 @@ In addition to the [standard mark options](#marks), the following optional chann
727727

728728
By default, the data is assumed to represent a single series (a single value that varies over time, *e.g.*). If the **z** channel is specified, data is grouped by *z* to form separate series. Typically *z* is a categorical value such as a series name. If **z** is not specified, it defaults to **stroke** if a channel, or **fill** if a channel.
729729

730-
The **stroke** defaults to currentColor. The **fill** defaults to none. If both the stroke and fill are defined as channels, or if the *z* channel is also specified, it is possible for the stroke or fill to vary within a series; varying color within a series is not supported, however, so only the first channel value for each series is considered. This limitation also applies to the **fillOpacity**, **strokeOpacity**, **strokeWidth**, and **title** channels. The **strokeWidth** defaults to 1.5 and the **strokeMiterlimit** defaults to 1.
730+
The **fill** defaults to none. The **stroke** defaults to currentColor if the fill is none, and to none otherwise. If both the stroke and fill are defined as channels, or if the *z* channel is also specified, it is possible for the stroke or fill to vary within a series; varying color within a series is not supported, however, so only the first channel value for each series is considered. This limitation also applies to the **fillOpacity**, **strokeOpacity**, **strokeWidth**, and **title** channels. The **strokeWidth** defaults to 1.5 and the **strokeMiterlimit** defaults to 1.
731731

732732
Points along the line are connected in input order. Likewise, if there are multiple series via the *z*, *fill*, or *stroke* channel, the series are drawn in input order such that the last series is drawn on top. Typically, the data is already in sorted order, such as chronological for time series; if sorting is needed, consider a [sort transform](#transforms).
733733

@@ -1006,10 +1006,10 @@ The *filter*, *sort* and *reverse* transforms are also available as functions, a
10061006
### Plot.sort(*order*, *options*)
10071007

10081008
```js
1009-
Plot.sort(d => d.value, options) // show data in ascending value order
1009+
Plot.sort("body_mass_g", options) // show data in ascending body mass order
10101010
```
10111011

1012-
Sorts the data by the specified *order*, which can be an acessor function, a comparator function, or a channel value definition.
1012+
Sorts the data by the specified *order*, which can be an acessor function, a comparator function, or a channel value definition such as a field name.
10131013

10141014
### Plot.reverse(*options*)
10151015

@@ -1022,10 +1022,10 @@ Reverses the order of the data.
10221022
### Plot.filter(*test*, *options*)
10231023

10241024
```js
1025-
Plot.filter(d => d.value > 3, options) // show data whose value is greater than three
1025+
Plot.filter(d => d.body_mass_g > 3000, options) // show data whose body mass is greater than 3kg
10261026
```
10271027

1028-
Filters the data given the specified *test*. The test can be given as an accessor function (which receives the datum and index), or as a channel value definition; truthy values are retained.
1028+
Filters the data given the specified *test*. The test can be given as an accessor function (which receives the datum and index), or as a channel value definition such as a field name; truthy values are retained.
10291029

10301030
### Bin
10311031

0 commit comments

Comments
 (0)