Skip to content

Commit b4697d1

Browse files
committed
Update
1 parent aa3f3e1 commit b4697d1

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

docs/guide.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -802,12 +802,11 @@ argument(s) to your slice source.
802802

803803
You can also pass extra keyword arguments to your slice source using the
804804
`slice_source_kwargs` setting. Keyword arguments passed as slice items take
805-
precedence, that is, they overwrite arguments passed by `slice_source_kawrgs`.
805+
precedence, that is, they overwrite arguments passed by `slice_source_kwargs`.
806806

807-
Slice arguments are passed to your slice source for every slice. If your slice source
808-
has many parameters that stay the same for all slices you may prefer providing
809-
parameters as settings in the configuration. This can be achieved using the `extra`
810-
setting:
807+
If your slice source has many parameters that stay the same for all slices you may
808+
prefer providing parameters as configuration settings, rather than function or class
809+
arguments. This can be achieved using the `extra` setting:
811810

812811
```json
813812
{
@@ -820,9 +819,10 @@ setting:
820819
```
821820

822821
To access the settings in `extra` your slice source function or class constructor
823-
must define a special argument named `ctx`. It must be a 1st positional argument or
822+
must define a special argument named `ctx`. It must be a 1ˢᵗ positional argument or
824823
a keyword argument. The argument `ctx` is the current processing context of type
825-
`zappend.api.Context` that also contains the configuration.
824+
`zappend.api.Context` that also contains the configuration. The settings in `extra`
825+
can be accessed using the dictionary returned from `ctx.config.extra`.
826826

827827
Here is a more advanced example of a slice source that opens datasets from a given
828828
file path and averages the values along the time dimension:

0 commit comments

Comments
 (0)