Skip to content

Commit

Permalink
DOC: Add note that the categories will be made unique and sorted. (#34)
Browse files Browse the repository at this point in the history
  • Loading branch information
snowman2 committed Aug 19, 2020
1 parent 69a3949 commit 26636b4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
4 changes: 3 additions & 1 deletion docs/examples/categorical.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"If your data is only a subset of all of the data, the list of categories you get will likely not be complete."
"If your data is only a subset of all of the data, the list of categories you get will likely not be complete.\n",
"\n",
"NOTE: The categories will be made unique and sorted internally if they are not already."
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion geocube/api/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def make_geocube(
:meth:`scipy.interpolate.griddata`.
categorical_enums: dict, optional
A dictionary of all categories for the table columns containing categorical
data.
data. The categories will be made unique and sorted if they are not already.
E.g. {'column_name': ['a', 'b'], 'other_column': ['c', 'd']}
rasterize_function: function, optional
Function to rasterize geometries. Other options are available in
Expand Down
3 changes: 2 additions & 1 deletion geocube/vector_to_cube.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ def __init__(self, vector_data, geobox_maker, fill=None, categorical_enums=None)
The value to fill in the grid with for nodata. Default is NaN.
categorical_enums: dict, optional
A dictionary of all categories for the table columns containing
categorical data.
categorical data. The categories will be made unique and sorted
if they are not already.
E.g. {'column_name': ['a', 'b'], 'other_column': ['c', 'd']}
"""
Expand Down

0 comments on commit 26636b4

Please sign in to comment.