Median price from the series of high and low prices
fints object for the
Data argument of
medprice is not
recommended. Use a matrix,
table instead for financial time series. For more information, see
Convert Financial Time Series Objects fints to Timetables.
Load the file
SimulatedStock.mat, which provides a timetable (
TMW) for financial data for TMW stock.
load SimulatedStock.mat MedianPrice = medprice(TMW); plot(MedianPrice.Time,MedianPrice.MedianPrice) title('Median Price for TMW')
Data— Data for high and low prices
Data for high and low prices, specified as a matrix, table, or timetable.
For matrix input,
Data is an
2 matrix of high and low
prices stored in the corresponding columns. The columns can be in either
order because the median price is the average of the high and low prices for
each period. Timetables and tables with
M rows must
contain a variable named
'Low' (case insensitive).
 Achelis, S. B. Technical Analysis from A to Z. Second Edition. McGraw-Hill, 1995, pp. 177–178.