What Is a Worked Example of Frama? A Clear, Verifiable Walkthrough

Explore What is a worked: mechanics, differences, limitations, and practical checks.

Direct answer

A worked example of Frama shows how the Fractal Adaptive Moving Average (Frama) value is computed from input price data using specific, stated assumptions (prices, window size, and smoothing rules). It is “worked” because it includes the intermediate numeric steps, not just the final line value.

Below is a self-contained scenario. It uses made-up price points (not live data) so you can independently recompute every intermediate quantity. The example is informational only and illustrates mechanics rather than predicting future market behavior.

Mechanism or definition

Frama is a moving average that adjusts its smoothing based on an estimate of how “fractal” or variable the recent price action is. In practice, implementations often:

  1. Split the recent lookback window into parts (for example, two half-windows).
  2. Compute measures of price variability for the full window and for each half.
  3. Convert those variability measures into a parameter that controls the effective smoothing rate.
  4. Blend the current Frama value toward the latest price using that smoothing rate.

Key idea: when recent price variation behaves like a strong trend (lower “relative variability” across windows), Frama tends to smooth less (respond faster). When variation looks more like noise or less coherent structure, it smooths more (respond slower). Exact formula details vary by implementation, so a worked example must state the specific rules it uses.

Evidence or example

Assumptions (state everything)

  • Data source: one-dimensional price series using “close” values.
  • We use a short illustrative lookback of 6 closes:
    • t=1..6: [100, 101, 102, 103, 102, 104]
  • We compute Frama at time t=6.
  • Lookback structure for this example:
    • Full window length: 4 (we consider the last 4 closes: 101, 102, 103, 102)
    • Two half-windows each of length 2:
      • Half A (earlier): 101, 102
      • Half B (later): 103, 102
  • Variability measure in this example: range = max(price) − min(price).
  • Conversion from variability to an “adaptive” factor:
    • Define N = ln(range_full / (range_halfA + range_halfB)) / ln(2)
    • Then clamp N to a reasonable interval: N_clamped = max(0, min(N, 1))
  • Smoothing-rate mapping:
    • alpha = 0.01 + (1 − N_clamped) * (0.99 − 0.01)
    • (This is a standard-style mapping example: alpha increases when N_clamped is smaller.)
  • Recursive update rule:
    • Frama_5 is set to 102 (an initial value assumption).
    • Frama_6 = alpha * Close_6 + (1 − alpha) * Frama_5

Important: These rules are part of the example assumptions. Another implementation could use different window lengths, variability measures, logarithm handling, or alpha mapping.

Step-by-step calculations

  1. Full window closes (t=3..6 using last 4 closes): [101, 102, 103, 102]
    • range_full = max(101,102,103,102) − min(101,102,103,102) = 103 − 101 = 2
  2. Half A closes: [101, 102]
    • range_halfA = 102 − 101 = 1
  3. Half B closes: [103, 102]
    • range_halfB = 103 − 102 = 1
  4. Denominator for N: range_halfA + range_halfB = 1 + 1 = 2
  5. Compute N:
    • range_full / (range_halfA + range_halfB) = 2 / 2 = 1
    • ln(1) = 0
    • N = ln(1) / ln(2) = 0
  6. Clamp:
    • N_clamped = max(0, min(0, 1)) = 0
  7. Compute alpha:
    • alpha = 0.01 + (1 − 0) * (0.99 − 0.01)
    • alpha = 0.01 + 1 * 0.98 = 0.99
  8. Update Frama:
    • Close_6 = 104
    • Frama_5 = 102
    • Frama_6 = 0.99 * 104 + (1 − 0.99) * 102
    • Frama_6 = 103.0 + 0.01 * 102
    • Frama_6 = 103.0 + 1.02 = 104.02

Result of this specific worked example: Frama_6 ≈ 104.02 given the stated assumptions.

What this example demonstrates

  • Every computed value depends on the earlier choices: window partitioning, the range definition, the log transform, clamping, and the alpha mapping.
  • With equal ranges in full and half windows, this example produced N=0, which mapped to a very high alpha (fast response). Different partitions or price values would change alpha.

Limitations and risks

  1. Formula differences across implementations

    • Frama names a family of adaptive moving averages. Practical implementations may vary in how they calculate fractal dimension, handle edge cases (like zero ranges), and map the adaptive factor to alpha. A worked example is only as transferable as its stated formula.
  2. Parameter sensitivity

    • Window sizes and clamping rules can strongly change the computed alpha and therefore the Frama level. If you change any assumed parameter (for example, window length or range measure), you must redo the calculations.
Trading foreign exchange and CFDs involves substantial risk. Information on FoxiForex is educational and is not personal financial advice. Sponsored placements are labelled clearly.