AnnotationDelete
AnnotationDelete[obj]
deletes all annotations of the object obj.
AnnotationDelete[{obj,itemspec}]
deletes all annotations of the items of obj specified by itemspec.
AnnotationDelete[spec,key]
deletes the annotation key specified by spec.
Details
- Typically used to delete annotations for objects and specific items in an object.
- AnnotationDelete[spec,key] returns the object specified in spec with the annotation key deleted.
- For standard annotations, AnnotationDelete effectively resets the value to the annotation default value.
- Possible objects with items that can be annotated:
-
Audio time points and time intervals BoundaryMeshRegion mesh cells Graph vertices and edges MeshRegion mesh cells - Item specification itemspec for each type of object is given in its reference page.
Examples
open allclose allBasic Examples (3)
Scope (7)
Graph & Networks (7)
Graph annotations (5)
Remove one annotation from vertices:
Remove all annotations from vertices:
Remove several annotations from vertices:
AnnotationDelete works with undirected graphs:
Vertex annotations (1)
Set several annotations for a graph:
Remove vertex annotations including VertexStyle:
Edge annotations (1)
Set several annotations for a graph:
Remove edge annotations including EdgeStyle:
Applications (2)
Linda wants to be anonymous in the presentation of the family gathering. Hide her vertex label:
Use Fold to apply AnnotationDelete repeatedly:
Properties & Relations (6)
Use Annotation as a wrapper to specify annotations in functions such as Graph:
Use AnnotationValue to extract values:
For undefined annotations, the value $Failed is returned:
Use AnnotationValue to set annotations in a graph:
The original graph has changed:
Use AnnotationValue to unset annotations in a graph:
The original graph has changed:
Use AnnotationKeys to test for the presence of a annotation:
Generate a list of vertex label rules:
Use Annotate to set a annotation without changing the original:
Possible Issues (1)
AnnotationValue is typically faster than AnnotationDelete:
Text
Wolfram Research (2019), AnnotationDelete, Wolfram Language function, https://reference.wolfram.com/language/ref/AnnotationDelete.html (updated 2020).
CMS
Wolfram Language. 2019. "AnnotationDelete." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2020. https://reference.wolfram.com/language/ref/AnnotationDelete.html.
APA
Wolfram Language. (2019). AnnotationDelete. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/AnnotationDelete.html