Ontology Version: 2.2.0

cacontology-training:MetricsConsistencyValidationShape leaf node


URI

https://cacontology.projectvic.org/training#MetricsConsistencyValidationShape

Label

Metrics Consistency Validation Shape

Description

Validates consistency between related metrics.

Shape Properties

Instances of cacontology-training:OutreachEventMetrics can have the following properties:

PROPERTY

MIN COUNT

MAX COUNT

TYPE

cacontology-training:OutreachEventMetrics
cacontology-training:outreachEventsCount 0 1 xsd:nonNegativeInteger
cacontology-training:totalAttendeesReached 0 1 xsd:nonNegativeInteger

Implementation

@prefix cacontology-training: <https://cacontology.projectvic.org/training#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
cacontology-training:MetricsConsistencyValidationShape a sh:NodeShape ;
    rdfs:label "Metrics Consistency Validation Shape"@en ;
    rdfs:comment "Validates consistency between related metrics."@en ;
    sh:sparql [ sh:message "Total attendees should be reasonable relative to event count."@en ;
            sh:select """
            SELECT $this
            WHERE {
                $this cacontology-training:outreachEventsCount ?events ;
                      cacontology-training:totalAttendeesReached ?attendees .
                FILTER (?attendees < ?events)
            }
        """ ] ;
    sh:targetClass cacontology-training:OutreachEventMetrics .