Historical High Price On A Date Formula in Excel
Gain valuable insights into past market trends by using the Historical High Price On A Date formula. This powerful Excel function from MarketXLS allows you to quickly retrieve the highest stock price for a specified symbol and date, enabling deeper analysis and better-informed decision-making.
Understanding Historical High Price On A Date
- The Historical High Price On A Date formula is designed to return the highest price of an asset (stock, index, option, or crypto) on a specific date.
- It is ideal for back-testing strategies, historical analysis, and comparing performance over time.
- By using this function, you can seamlessly integrate real market data into your Excel workflows.
Syntax and Parameters
Below is the official syntax for the High_Historical
function:
=High_Historical(Symbol, OnDate)
Parameter | Description | Required | Example |
---|---|---|---|
Symbol | The stock or asset symbol. Accepts various symbol formats like "MSFT" , "^SPX" , "@MSFT 110122C00020000" , or "BTCUSD:DEFAULT" . |
Yes | "MSFT" |
OnDate | The date for which the high price is to be returned. Accepts cell references (e.g. A1 ), direct dates (e.g. "2024-03-15" ), or Excel date functions. |
Yes | TODAY()-1 |
Return Value:
• Returns the highest price as a numeric value (e.g., 305.67).
• Returns "NA"
if the symbol is invalid, license is not valid, date is not a valid trading day (or falls on a weekend/holiday), or if a data retrieval error occurs.
?? Note: Ensure you use the correct symbol format and date format (
YYYY-MM-DD
) for reliable results.
Examples and Usage
Below are practical ways to use the High_Historical
function in Excel:
-
Direct Date Entry:
=High_Historical("MSFT","2020-11-19")
Retrieves Microsoft’s highest price on November 19, 2020.
-
Cell References:
=High_Historical(A1,B1)
Where cell A1 contains the symbol (e.g.,
"MSFT"
) and B1 contains the date (e.g.,2020-11-19
). -
Combining with Excel Date Functions:
=High_Historical("BTCUSD:DEFAULT",TEXT(A1,"yyyy-mm-dd"))
If
A1
contains a valid Excel date,TEXT(A1,"yyyy-mm-dd")
ensures the correct format is passed to the function.
? Pro Tip: For historical data on indices such as the S&P 500, simply use
"^SPX"
in place of the stock symbol.
Common Questions
-
What if the function returns “NA”?
- Ensure the symbol exists, your license is active, and the date cited is not a market holiday or invalid date.
-
Can I use this function for weekend dates?
- The function attempts to adjust for weekends; however, if no valid trading data is found, it will still return
"NA"
.
- The function attempts to adjust for weekends; however, if no valid trading data is found, it will still return
-
How do I optimize performance?
- Use cell references and batch your data requests to limit repetitive queries. MarketXLS caching mechanisms help improve speed.
-
Are international stocks or indices supported?
- Yes, provided you use the correct symbol format (e.g., “.PA”, “.AS”, “^NDX”) and a valid MarketXLS subscription level that supports those markets.
By incorporating the Historical High Price On A Date formula, you can seamlessly integrate real-time historical data for more robust analyses. Combine it with other MarketXLS functions to build powerful financial models and manage your investment strategies effectively.