Hi,
I'm processing the data from an oscilloscope. The natural way to 
encapsulate them is to have a structure in a form of

type Wfm  
  xorigin
  xinc
  len
  ydata 
  properties::Dict{ASCIIString,Any}
end

, where X represents time and Y  data are equidistantly spaced  in time. To 
access a subset one would index into Wfm using the range defined in the X 
axis:

function getindex(W::Wfm, I::FloatRange)
function getx(W::Wfm, I::FloatRange)

wfm = wfmopen("file.h5")
x = getx(wfm, -1e-8:1e-8)
y = wfm[-1e-8:1e-8]
plot(x,y)

However, this is not possible. During the FloatRange construction omitting the 
stepsize the end value is lost and it is not possible to reconstruct again.
> a = -1e-8:1e-8
> dump(a)


FloatRange{Float64} 
  start: Float64 -1.0e-8
  step: Float64 1.0
  len: Float64 1.0
  divisor: Float64 1.0


I understand that for array indexing or array construction the current 
behavior of FloatRange with default stepsize=1.0 is OK, but it blocks much 
more appealing general use-cases not related to array indexing. And the 
notation xmin:xmax is appealing and very well readable. Much better that 
forcing the user to write -1e-8:1e-16:1e8 or -1e-8:eps(Float64):1e-8.

Do you think an addition of an exact_end field into this type in Base would 
be worth the effort and storage space?

Petr

Reply via email to