High Price Between 2 Dates In History
Returns the highest value of a specified price field between two dates. By default, it uses closing prices.
Supported Symbol Formats
| Type | Format | Example |
|---|---|---|
| US Stocks | SYMBOL | AAPL, MSFT |
| ETFs | SYMBOL | SPY, QQQ |
Parameters
| Parameter | Description | Default |
|---|---|---|
| Symbol | Stock ticker | Required |
| StartDate | Start of range | Required |
| EndDate | End of range | Required |
| DataField | Price field | "close" |
DataField Options
close- Closing prices (default)high- Daily high priceslow- Daily low pricesopen- Opening prices
Syntax
=custom_dates_high(Symbol, StartDate, EndDate, [DataField])Parameters
symbolstringRequired
dataFieldstringRequired
close, high, low, volume
startDatedateRequired
endDatedateRequired
Returns
number
Highest value of specified field between dates
Examples
=custom_dates_high("AAPL", DATE(2024,1,1), DATE(2024,3,31))=custom_dates_high("AAPL", DATE(2024,1,1), DATE(2024,3,31), "high")=custom_dates_high("MSFT", DATE(2024,6,1), DATE(2024,8,31))=custom_dates_high(A1, B1, C1, "close")When to Use
- Analyzing price peaks in custom periods
- Quarterly or monthly high analysis
- Event-based price studies
- Custom date range resistance levels
When NOT to Use
| Scenario | Use Instead |
|---|---|
| Need 52-week high | FiftyTwoWeekHigh() |
| Need X-week high | x_week_high() |
| Need low instead | custom_dates_low() |
Common Issues & FAQ
What if dates are reversed (end before start)?
The function may return incorrect results. Ensure start date is before end date.
What DataField options are available?
Use "close" (default), "high", "low", or "open".
Related Formulas
More MarketXLS MarketXLS Analytics formulas you can use in the same worksheet:
