Previous Close (On Demand)
Gets the previous trading day's closing price on-demand (snapshot) from QuoteMedia. This is the reference price for calculating daily change.
Supported Symbol Formats
| Type | Format | Example |
|---|---|---|
| US Stocks | SYMBOL | AAPL, MSFT |
| ETFs | SYMBOL | SPY, QQQ |
| Indices | ^SYMBOL | ^SPX, ^VIX |
Notes
- Returns a snapshot (does not auto-update)
- Used as baseline for daily change calculations
- Important for gap analysis
Examples
=QM_PreviousClose("AAPL")=QM_PreviousClose("MSFT")=QM_PreviousClose("SPY")=QM_PreviousClose(A1)=QM_Last("AAPL")-QM_PreviousClose("AAPL")When to Use
- Gap analysis (open vs previous close)
- Change calculations
- Static reports
- Reference price comparisons
When NOT to Use
| Scenario | Use Instead |
|---|---|
| Need streaming previous close | QM_Stream_PreviousClose() |
| Need historical close on date | Close_Historical() |
| Need today's close | QM_Last() |
Common Issues & FAQ
Q: What is previous close? A: The official closing price from the most recent completed trading session (typically yesterday).
Q: How do I calculate the gap?
A: Use =QM_Open("AAPL")-QM_PreviousClose("AAPL").
Q: Why am I getting #N/A? A: Check that symbol format is correct.
