---
title: "Nearness Ratio"
method: POST
path: "/assets/indicators/nearness-ratio"
tags: ["Assets / Indicators"]
---

# Nearness Ratio

`POST /assets/indicators/nearness-ratio`

Compute the nearness ratio of an asset.

References
* [GEORGE, T.J. and HWANG, C.-Y. (2004), The 52-Week High and Momentum Investing. The Journal of Finance, 59: 2145-2176](https://onlinelibrary.wiley.com/doi/abs/10.1111/j.1540-6261.2004.00695.x)

## Request body

- union
  - object
    - `assets` object[], required
      - `assetReturns` number[], required — assetReturns[t] is the logarithmic return of the asset at the time t
      - `assetNearnessRatioSkipPeriod` integer — The number of the most recent periods excluded from the asset nearness ratio computation; must be < assetNearnessRatioFormationPeriod
      - `assetNearnessRatioFormationPeriod` integer, required — The look back period over which to compute the asset nearness ratio
  - object
    - `assets` object[], required
      - `assetPrices` object[], required — assetPrices[t] contains price information for the asset at the date t
        - `date` string, required — The date corresponding to the date t in format YYYY-MM-DD; all dates must be distinct
        - `close` number, required — The close price of the asset at the date t
      - `assetNearnessRatioSkipPeriod` integer — The number of the most recent periods excluded from the asset nearness ratio computation; must be < assetNearnessRatioFormationPeriod
      - `assetNearnessRatioFormationPeriod` integer, required — The look back period over which to compute the asset nearness ratio

## Response `200`

OK

- object
  - `assets` object[], required
    - `assetNearnessRatioHigh` number, required — The asset nearness ratio using the highest past asset price over the computation period as a reference point
    - `assetNearnessRatioLow` number, required — The asset nearness ratio using the lowest past asset price over the computation period as a reference point

---

[API](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer.md) · [All operations](https://skmtc.net/portfoliooptimizer/apis/portfolio-optimizer/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/portfoliooptimizer/portfolio-optimizer/revisions/dee9caba1913/schema)
