I’m trying to build a data type to hold a measurements of a quantity. I know that this quantity will be a length, but don’t know a priori what unit that length will be. I’m having a bit of trouble coming up with syntax to guarantee that heights
will be a length using the Unitful
types.
using Unitful
struct Measurements
heights::Array{Unitful.Quantity,1} # this line
end
Is there a better way to do this? Thanks for the help!
2 posts - 2 participants