# NOT RUN {
# aggregate price data to the 30 second frequency
aggregatePrice(sample_tdata_microseconds, on = "secs", k = 30)
# aggregate price data to the 30 second frequency including zero return price changes
aggregatePrice(sample_tdata_microseconds, on = "secs", k = 30)
# aggregate price data to half a second frequency including zero return price changes
aggregatePrice(sample_tdata_microseconds, on = "milliseconds", k = 500, fill = TRUE)
# }
Run the code above in your browser using DataLab