Skip to content

Commit

Permalink
Make report curve units more flexible/optional
Browse files Browse the repository at this point in the history
Decouple X and Y unit requirements for the curve schema.
This allows mixing values with and without units.
An example case is probability (unitless) vs. time (hours).

With the coupled schema,
both X and Y must or must not have units.
The above example would fail to validate.
  • Loading branch information
rakhimov committed Feb 27, 2017
1 parent a3a3970 commit 928e1b8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mef/schema/curves.rnc
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ curve =
(attribute X-title { xsd:string },
attribute Y-title { xsd:string },
attribute Z-title { xsd:string }?)?,
(attribute X-unit { unit },
attribute Y-unit { unit },
attribute Z-unit { unit }?)?,
attribute X-unit { unit }?,
attribute Y-unit { unit }?,
attribute Z-unit { unit }?,
element point {
attribute X { xsd:double },
attribute Y { xsd:double },
attribute Z { xsd:double }?
}*
}

unit = "seconds" | "hours"
unit = "seconds" | "hours" | "seconds-1" | "hours-1" | "years" | "years-1"

0 comments on commit 928e1b8

Please sign in to comment.