{
  "schema_version": "1.0",
  "signal_id": "close-crosses-above-20dma",
  "slug": "close-crosses-above-20dma",
  "family": "price-structure",
  "registry_version": 1,
  "registered_on": "2026-09-05",
  "computed_at": "2026-09-05T09:40:52Z",
  "code_commit": "283c309",
  "data_as_of": "2026-08-06",
  "universe_as_of": "point-in-time",
  "sample_grade": "STRONG",
  "headline_horizon": 5,
  "title": "Close crosses above 20dma",
  "plain_english": "The stock closed back above its 20-day average price after having spent at least five of the previous ten sessions below it.",
  "definition": "close[t] > sma(close, 20)[t]\nAND close[t-1] <= sma(close, 20)[t-1]\nAND count(close < sma(close, 20) over t-10..t-1) >= 5",
  "headline_parameters": {
    "ma_length": 20,
    "days_below": 5
  },
  "sample": {
    "n_raw": 83895,
    "n_eff": 60339.8,
    "deff": 1.39,
    "rho": 0.0175,
    "m_bar": 23.32,
    "n_eff_raw_design": 16512.8,
    "rho_raw_design": 0.1828,
    "deff_raw_design": 5.081,
    "distinct_stocks": 2027,
    "distinct_dates": 3597,
    "date_range": [
      "2011-10-03",
      "2026-08-05"
    ],
    "censoring_rate": 0.0054,
    "max_quarter_share": 0.0376,
    "max_stock_share": 0.0021,
    "max_sector_share": null,
    "control_rung_distribution": {
      "0": 0.7487,
      "1": 0.2207,
      "2": 0.0303,
      "3": 0.0002,
      "4": 0.0
    },
    "mean_controls_per_event": 19.31
  },
  "horizons": [
    {
      "days": 1,
      "n_eff": 66691.3,
      "hit_rate": 0.4269,
      "control_hit_rate": 0.4377,
      "lift": -0.0108,
      "lift_ci95": [
        -0.015,
        -0.0068
      ],
      "lift_ci_method": "cluster_bootstrap_date_block_B10000_BCa",
      "lift_p_value": 0.0001,
      "median_change": -0.00309,
      "control_median_change": -0.00231,
      "excess_median": -0.00079,
      "trimmed_mean_change": -0.00136,
      "spread": {
        "p10": -0.0276,
        "p25": -0.0151,
        "p75": 0.0101,
        "p90": 0.027
      },
      "mfe": 0.0129,
      "mae": -0.015,
      "break_even_hit_rate": 0.5556,
      "break_even_assumptions": {
        "bracket": 0.02,
        "round_trip_cost": 0.002225,
        "impact": 0.0
      },
      "benchmark_median_change": 0.0,
      "interval_includes_zero": false,
      "interval_check": {
        "bootstrap_half_width": 0.00411,
        "analytic_clustered_half_width": 0.00364,
        "wilson_on_n_eff_half_width": 0.00375,
        "ratio_bootstrap_to_analytic": 1.127,
        "ratio_bootstrap_to_wilson_on_rate": 1.094
      },
      "n_eff_raw_design": 25666.4
    },
    {
      "days": 3,
      "n_eff": 64312.2,
      "hit_rate": 0.4564,
      "control_hit_rate": 0.4731,
      "lift": -0.0168,
      "lift_ci95": [
        -0.0213,
        -0.012
      ],
      "lift_ci_method": "cluster_bootstrap_date_block_B10000_BCa",
      "lift_p_value": 0.0001,
      "median_change": -0.00351,
      "control_median_change": -0.00157,
      "excess_median": -0.00194,
      "trimmed_mean_change": -7e-05,
      "spread": {
        "p10": -0.0486,
        "p25": -0.0257,
        "p75": 0.0215,
        "p90": 0.053
      },
      "mfe": 0.0237,
      "mae": -0.0248,
      "break_even_hit_rate": 0.5556,
      "break_even_assumptions": {
        "bracket": 0.02,
        "round_trip_cost": 0.002225,
        "impact": 0.0
      },
      "benchmark_median_change": -0.00132,
      "interval_includes_zero": false,
      "interval_check": {
        "bootstrap_half_width": 0.00463,
        "analytic_clustered_half_width": 0.00362,
        "wilson_on_n_eff_half_width": 0.00385,
        "ratio_bootstrap_to_analytic": 1.278,
        "ratio_bootstrap_to_wilson_on_rate": 1.203
      },
      "n_eff_raw_design": 19057.1
    },
    {
      "days": 5,
      "n_eff": 60339.8,
      "hit_rate": 0.4665,
      "control_hit_rate": 0.4839,
      "lift": -0.0174,
      "lift_ci95": [
        -0.0221,
        -0.0124
      ],
      "lift_ci_method": "cluster_bootstrap_date_block_B10000_BCa",
      "lift_p_value": 0.0001,
      "median_change": -0.00349,
      "control_median_change": -0.00092,
      "excess_median": -0.00257,
      "trimmed_mean_change": 0.00121,
      "spread": {
        "p10": -0.0634,
        "p25": -0.0333,
        "p75": 0.0302,
        "p90": 0.0717
      },
      "mfe": 0.0318,
      "mae": -0.0315,
      "break_even_hit_rate": 0.5556,
      "break_even_assumptions": {
        "bracket": 0.02,
        "round_trip_cost": 0.002225,
        "impact": 0.0
      },
      "benchmark_median_change": -0.00336,
      "interval_includes_zero": false,
      "interval_check": {
        "bootstrap_half_width": 0.00485,
        "analytic_clustered_half_width": 0.00368,
        "wilson_on_n_eff_half_width": 0.00398,
        "ratio_bootstrap_to_analytic": 1.317,
        "ratio_bootstrap_to_wilson_on_rate": 1.219
      },
      "n_eff_raw_design": 16512.8,
      "distribution": {
        "bin_lo": -0.13651,
        "bin_hi": 0.18859,
        "bin_width": 0.013004,
        "event_share": [
          0.00485,
          0.00732,
          0.01132,
          0.01822,
          0.02633,
          0.04078,
          0.05963,
          0.08277,
          0.10302,
          0.11756,
          0.11929,
          0.09854,
          0.07884,
          0.06035,
          0.04636,
          0.03332,
          0.02501,
          0.01922,
          0.01289,
          0.01052,
          0.00791,
          0.00573,
          0.00409,
          0.00334,
          0.00279
        ],
        "control_share": [
          0.00462,
          0.00732,
          0.01113,
          0.01686,
          0.02533,
          0.03728,
          0.054,
          0.07544,
          0.1009,
          0.12021,
          0.12447,
          0.10508,
          0.0827,
          0.06371,
          0.04657,
          0.03403,
          0.02495,
          0.01853,
          0.01371,
          0.01007,
          0.00747,
          0.00561,
          0.00423,
          0.00326,
          0.00255
        ]
      }
    },
    {
      "days": 10,
      "n_eff": 64565.0,
      "hit_rate": 0.4791,
      "control_hit_rate": 0.4927,
      "lift": -0.0136,
      "lift_ci95": [
        -0.0188,
        -0.0084
      ],
      "lift_ci_method": "cluster_bootstrap_date_block_B10000_BCa",
      "lift_p_value": 0.0001,
      "median_change": -0.00321,
      "control_median_change": 5e-05,
      "excess_median": -0.00326,
      "trimmed_mean_change": 0.00371,
      "spread": {
        "p10": -0.0878,
        "p25": -0.0455,
        "p75": 0.0458,
        "p90": 0.1037
      },
      "mfe": 0.0475,
      "mae": -0.0447,
      "break_even_hit_rate": 0.5556,
      "break_even_assumptions": {
        "bracket": 0.02,
        "round_trip_cost": 0.002225,
        "impact": 0.0
      },
      "benchmark_median_change": -0.00863,
      "interval_includes_zero": false,
      "interval_check": {
        "bootstrap_half_width": 0.00522,
        "analytic_clustered_half_width": 0.00352,
        "wilson_on_n_eff_half_width": 0.00385,
        "ratio_bootstrap_to_analytic": 1.481,
        "ratio_bootstrap_to_wilson_on_rate": 1.355
      },
      "n_eff_raw_design": 15578.0
    },
    {
      "days": 20,
      "n_eff": 66933.8,
      "hit_rate": 0.4997,
      "control_hit_rate": 0.5099,
      "lift": -0.0102,
      "lift_ci95": [
        -0.015,
        -0.0049
      ],
      "lift_ci_method": "cluster_bootstrap_date_block_B10000_BCa",
      "lift_p_value": 0.0001,
      "median_change": 0.0,
      "control_median_change": 0.00349,
      "excess_median": -0.00349,
      "trimmed_mean_change": 0.01073,
      "spread": {
        "p10": -0.1204,
        "p25": -0.0602,
        "p75": 0.072,
        "p90": 0.1547
      },
      "mfe": 0.0717,
      "mae": -0.0638,
      "break_even_hit_rate": 0.5556,
      "break_even_assumptions": {
        "bracket": 0.02,
        "round_trip_cost": 0.002225,
        "impact": 0.0
      },
      "benchmark_median_change": -0.02163,
      "interval_includes_zero": false,
      "interval_check": {
        "bootstrap_half_width": 0.00508,
        "analytic_clustered_half_width": 0.00343,
        "wilson_on_n_eff_half_width": 0.00379,
        "ratio_bootstrap_to_analytic": 1.481,
        "ratio_bootstrap_to_wilson_on_rate": 1.341
      },
      "n_eff_raw_design": 14743.8
    }
  ],
  "gates": [
    {
      "id": "n_eff",
      "label": "Effective sample size",
      "threshold": ">= 100",
      "observed": "60340",
      "passed": true
    },
    {
      "id": "distinct_dates",
      "label": "Distinct event dates",
      "threshold": ">= 60",
      "observed": "3597",
      "passed": true
    },
    {
      "id": "distinct_stocks",
      "label": "Distinct securities",
      "threshold": ">= 25",
      "observed": "2027",
      "passed": true
    },
    {
      "id": "calendar_span",
      "label": "Calendar span",
      "threshold": ">= 5 years",
      "observed": "14.8 years",
      "passed": true
    },
    {
      "id": "quarter_share",
      "label": "Largest share in one quarter",
      "threshold": "<= 20.0%",
      "observed": "3.8%",
      "passed": true
    },
    {
      "id": "stock_share",
      "label": "Largest share from one security",
      "threshold": "<= 5.0%",
      "observed": "0.2%",
      "passed": true
    },
    {
      "id": "censoring",
      "label": "Censoring rate",
      "threshold": "<= 2.0%",
      "observed": "0.5%",
      "passed": true
    },
    {
      "id": "control_match",
      "label": "Events on relaxation rung 3-4",
      "threshold": "<= 20.0%",
      "observed": "0.0%",
      "passed": true
    }
  ],
  "multiple_testing": {
    "variants_in_grid": 25,
    "tests_on_site": 1125,
    "bh_fdr_q": 0.1,
    "passes_fdr": true,
    "adjusted_p": 0.00018,
    "raw_p": 0.0001
  },
  "years": [
    {
      "year": 2011,
      "n_eff": 577.0,
      "lift": 0.012
    },
    {
      "year": 2012,
      "n_eff": 2094.8,
      "lift": 0.0083
    },
    {
      "year": 2013,
      "n_eff": 1991.5,
      "lift": -0.0034
    },
    {
      "year": 2014,
      "n_eff": 2531.5,
      "lift": -0.0218
    },
    {
      "year": 2015,
      "n_eff": 3085.0,
      "lift": -0.0271
    },
    {
      "year": 2016,
      "n_eff": 2903.6,
      "lift": -0.0245
    },
    {
      "year": 2017,
      "n_eff": 3605.1,
      "lift": -0.0371
    },
    {
      "year": 2018,
      "n_eff": 3606.2,
      "lift": -0.0096
    },
    {
      "year": 2019,
      "n_eff": 3010.1,
      "lift": -0.0113
    },
    {
      "year": 2020,
      "n_eff": 3082.1,
      "lift": -0.0102
    },
    {
      "year": 2021,
      "n_eff": 4670.4,
      "lift": -0.0313
    },
    {
      "year": 2022,
      "n_eff": 4699.3,
      "lift": -0.0231
    },
    {
      "year": 2023,
      "n_eff": 5192.0,
      "lift": -0.0064
    },
    {
      "year": 2024,
      "n_eff": 6104.2,
      "lift": -0.025
    },
    {
      "year": 2025,
      "n_eff": 6382.4,
      "lift": -0.013
    },
    {
      "year": 2026,
      "n_eff": 3731.1,
      "lift": -0.0109
    }
  ],
  "regimes": [
    {
      "trend": "above",
      "vol_tercile": 1,
      "n_eff": 139.7,
      "lift": 0.0952
    },
    {
      "trend": "above",
      "vol_tercile": 2,
      "n_eff": 262.3,
      "lift": 0.0362
    },
    {
      "trend": "above",
      "vol_tercile": 3,
      "n_eff": 1234.2,
      "lift": -0.0167
    },
    {
      "trend": "below",
      "vol_tercile": 1,
      "n_eff": 18882.8,
      "lift": -0.0187
    },
    {
      "trend": "below",
      "vol_tercile": 2,
      "n_eff": 19508.6,
      "lift": -0.0171
    },
    {
      "trend": "below",
      "vol_tercile": 3,
      "n_eff": 20061.5,
      "lift": -0.018
    }
  ],
  "robustness": {
    "split_half_same_sign": true,
    "split_half": {
      "first": -0.0187,
      "second": -0.0161
    },
    "years_positive": 14,
    "years_total": 16,
    "non_overlapping_lift": -0.019,
    "sector_matched_lift": null,
    "cost_adjusted_lift": -0.0158,
    "censoring_worst_case_lift": -0.02,
    "parameter_grid_median_lift": -0.0173,
    "knife_edge": false,
    "parameter_grid": {
      "axis_a": "ma_length",
      "axis_b": "days_below",
      "cells": [
        {
          "a": 16,
          "b": 3,
          "lift": -0.0145,
          "n_eff": 117372.0
        },
        {
          "a": 16,
          "b": 4,
          "lift": -0.0147,
          "n_eff": 107288.0
        },
        {
          "a": 16,
          "b": 5,
          "lift": -0.0155,
          "n_eff": 97319.0
        },
        {
          "a": 16,
          "b": 6,
          "lift": -0.0164,
          "n_eff": 87229.0
        },
        {
          "a": 16,
          "b": 7,
          "lift": -0.0174,
          "n_eff": 76746.0
        },
        {
          "a": 18,
          "b": 3,
          "lift": -0.015,
          "n_eff": 108469.0
        },
        {
          "a": 18,
          "b": 4,
          "lift": -0.0155,
          "n_eff": 99139.0
        },
        {
          "a": 18,
          "b": 5,
          "lift": -0.0162,
          "n_eff": 89910.0
        },
        {
          "a": 18,
          "b": 6,
          "lift": -0.0173,
          "n_eff": 80857.0
        },
        {
          "a": 18,
          "b": 7,
          "lift": -0.0183,
          "n_eff": 71482.0
        },
        {
          "a": 20,
          "b": 3,
          "lift": -0.0157,
          "n_eff": 100969.0
        },
        {
          "a": 20,
          "b": 4,
          "lift": -0.0164,
          "n_eff": 92327.0
        },
        {
          "a": 20,
          "b": 5,
          "lift": -0.0174,
          "n_eff": 83895.0
        },
        {
          "a": 20,
          "b": 6,
          "lift": -0.0181,
          "n_eff": 75512.0
        },
        {
          "a": 20,
          "b": 7,
          "lift": -0.0189,
          "n_eff": 66950.0
        },
        {
          "a": 22,
          "b": 3,
          "lift": -0.0155,
          "n_eff": 95156.0
        },
        {
          "a": 22,
          "b": 4,
          "lift": -0.0163,
          "n_eff": 86949.0
        },
        {
          "a": 22,
          "b": 5,
          "lift": -0.0175,
          "n_eff": 78872.0
        },
        {
          "a": 22,
          "b": 6,
          "lift": -0.0176,
          "n_eff": 71150.0
        },
        {
          "a": 22,
          "b": 7,
          "lift": -0.0183,
          "n_eff": 63239.0
        },
        {
          "a": 24,
          "b": 3,
          "lift": -0.0162,
          "n_eff": 89881.0
        },
        {
          "a": 24,
          "b": 4,
          "lift": -0.0175,
          "n_eff": 82230.0
        },
        {
          "a": 24,
          "b": 5,
          "lift": -0.018,
          "n_eff": 74602.0
        },
        {
          "a": 24,
          "b": 6,
          "lift": -0.0187,
          "n_eff": 67272.0
        },
        {
          "a": 24,
          "b": 7,
          "lift": -0.02,
          "n_eff": 59924.0
        }
      ]
    },
    "entry_delayed_lift": -0.0126,
    "placebo_lift": 0.0052
  },
  "control_seed": 42,
  "control_stats": {
    "events": 83955,
    "events_with_controls": 83955,
    "unmatched": 0,
    "mean_controls_per_event": 19.32
  },
  "cost_assumption_source": {
    "generated_at": "2026-09-05T04:19:20Z",
    "cash_equity_rate_version": "2026-09-05"
  },
  "license": "https://creativecommons.org/licenses/by/4.0/",
  "method_url": "https://learnnifty.com/base-rates/methodology/",
  "disclaimer": "Historical frequencies only. Not investment advice, a recommendation or a price target. LearnNifty is not registered with SEBI as an Investment Adviser or Research Analyst."
}