- Newest
- Most votes
- Most comments
Hello,
The %%sparql magic in Neptune Notebooks comes with a suite of options that can be used to customize your query visualization. You can find more information about these options by running %%sparql with the --help
option and anything in the cell body:
%%sparql --help
x
The --group-by
option would be the most useful in regards to your question. When specified with any custom attribute name, --group-by
will color the visualized nodes based on the value of the attribute.
For example, if you wanted to create color groups on the value of the attribute node attribute value
, run:
%%sparql --group-by value
...
You also have the ability to choose a different attribute to group by for each node type
. This can be done by first defining the groups in an empty cell:
groups = '{"uri":"value","identifier":"type"}'
Then using the Jupyter line variable injection syntax to assign the variable value to --group-by
:
%%sparql --group-by $groups
...
Relevant content
- asked a year ago
- asked 2 years ago
- asked 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated a month ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated a year ago