Using Astronomical Data to Create Trading Rules

Discussion in 'Strategy Building' started by ph1l, Mar 26, 2023.

  1. ph1l

    ph1l

    In a previous thread, I showed an example of astronomical and price data as inputs to create trading rules. Here, I'll show something similar for using only astronomical data as input including how these trading rules worked on out-of-sample data.

    The input data is from the Jet Propulsion Laboratory's Horizons ephemeris computation system. The inputs are as an observer would see from New York, NY at 20:00 UTC. Each input is for a celestial body (Moon, Sun Mercury, Venus, Mars, Jupiter, or Saturn) the number of calendar days from today (e.g., 000 for today or 007 for one week ago) and an input type:
    • Azimuth -- position on the horizon: 0 to 360 degrees where 0 is north
    • AzimuthRelNorth - position on the horizon: -180 to 180 degrees where 0 is north
    • AzimuthRelSouth - position on the horizon: -180 to 180 degrees where 0 is south
    • Elevation - position above or below the horizon: -90 to 90 degrees
    • IllumPct - percent of body illuminated from the Sun: 0 through 100 percent
    • IllumPctRelNew - percent of body illuminated from the Sun: -50 through 50 percent where 0 is 0 percent illuminated
    • IllumPctRelFull - percent of body illuminated from the Sun: -50 through 50 percent where 0 is 100 percent illuminated
    • AngDiam - angular diameter in arc seconds

    For various combinations of inputs, my rule generation software trained simulated trades using S&P 500 index prices and ephemeris data from the day before entering a trade from 1957-03-04 through 2003-05-16 where a trade was simulated going long at the close the next trading day and exiting at the close 10 trading days after entry (11632 simulated trades). Validation data unseen during training was for the day before entering a trade from 2003-05-20 through 2023-03-07 where the simulated trade was also long at the next close and exiting 10 trading days after entry (4985 simulated trades).

    In my previous thread, I used genetic programming where the software created set of trading rules. Here, I manually wrote some smaller combinations of trading rules as templates and used genetic optimization to fill in constant values to create trading rules. Then, I combined trading rules from different training runs to create a larger set of rules for a higher number of trades.

    In the perl rules below (you can ignore the $ in each variable name), when the return is set to 1, the trade would be taken at the next trading day's close. Each nonblank line is from a separate training run.
    Code:
    if ( $VenusAzimuthRelSouth000 >= 14.2417 ) { if ( $VenusAzimuthRelSouth000 <= 90.3941 ) { if ( $VenusElevation000 >= -13.9106 ) { if ( $VenusElevation000 <= 31.4736 ) { if ( $MercuryIllumPctRelNew000 >= -46.847 ) { if ( $MercuryIllumPctRelNew000 <= 49.316 ) { if ( $VenusIllumPctRelNew000 >= -11.873 ) { if ( $VenusIllumPctRelNew000 <= 49.968 ) { if ( $VenusAngDiam000 >= 10.4643 ) { if ( $VenusAngDiam000 <= 40.8093 ) { $return =   1 ; } } } } } } } } } }
    
    if ( $SaturnAzimuthRelSouth000 >= -157.573 ) { if ( $SaturnAzimuthRelSouth000 <= 98.0348 ) { if ( $SaturnElevation000 >= -65.7537 ) { if ( $SaturnElevation000 <= -19.5381 ) { if ( $MoonIllumPctRelNew000 >= -49.881 ) { if ( $MoonIllumPctRelNew000 <= 48.553 ) { if ( $SaturnIllumPctRelNew000 >= -0.235 ) { if ( $SaturnIllumPctRelNew000 <= -0.006 ) { if ( $SaturnAngDiam000 >= 15.6943 ) { if ( $SaturnAngDiam000 <= 20.2308 ) { $return =   1 ; } } } } } } } } } }
    
    if ( $SunAzimuth000 >= 222.538 ) { if ( $SunAzimuth000 <= 224.48 ) { if ( $SunElevation000 >= 12.4349 ) { if ( $SunElevation000 <= 21.3683 ) { if ( $SunAngDiam000 >= 1927.08 ) { if ( $SunAngDiam000 <= 1951.86 ) { if ( $SunAngDiam000 > $SunAngDiam007 ) { $return =   1 ; } } } } } } }
    
    if ( $MarsAzimuth000 >= 67.5343 ) { if ( $MarsAzimuth000 <= 279.061 ) { if ( $MarsElevation000 >= -10.2939 ) { if ( $MarsElevation000 <= 43.6832 ) { if ( $MarsIllumPctRelNew000 >= -12.731 ) { if ( $MarsIllumPctRelNew000 <= -0.937 ) { if ( $MarsAngDiam000 >= 5.25738 ) { if ( $MarsAngDiam000 <= 13.6376 ) { $return =   1 ; } } } } } } } }
    
    if ( $SaturnAzimuthRelSouth000 >= -158.01 ) { if ( $SaturnAzimuthRelSouth000 <= 97.2686 ) { if ( $SaturnElevation000 >= -61.8973 ) { if ( $SaturnElevation000 <= -16.2652 ) { if ( $SaturnIllumPctRelNew000 >= -0.235 ) { if ( $SaturnIllumPctRelNew000 <= -0.009 ) { if ( $SaturnAngDiam000 >= 15.6356 ) { if ( $SaturnAngDiam000 <= 20.2175 ) { $return =   1 ; } } } } } } } }
    
    if ( $MoonAzimuth000 >= 37.9644 ) { if ( $MoonAzimuth000 <= 290.125 ) { if ( $MoonElevation000 >= -24.471 ) { if ( $MoonElevation000 <= 31.9772 ) { if ( $MoonIllumPct000 >= 0.428 ) { if ( $MoonIllumPct000 <= 99.829 ) { if ( $MoonAngDiam000 >= 1792.15 ) { if ( $MoonAngDiam000 <= 1924.56 ) { if ( $MoonAzimuth007 >= 108.057 ) { if ( $MoonAzimuth007 <= 251.904 ) { if ( $MoonElevation007 >= -0.4395 ) { if ( $MoonElevation007 <= 59.9465 ) { if ( $MoonIllumPct007 >= 1.314 ) { if ( $MoonIllumPct007 <= 68.382 ) { if ( $MoonAngDiam007 >= 1756.77 ) { if ( $MoonAngDiam007 <= 1994.2 ) { if ( $MoonIllumPct000 > $MoonIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $MoonAzimuth000 >= 0.409 ) { if ( $MoonAzimuth000 <= 69.4272 ) { if ( $MoonElevation000 >= -59.3868 ) { if ( $MoonElevation000 <= -8.198 ) { if ( $MoonIllumPct000 >= 57.982 ) { if ( $MoonIllumPct000 <= 99.789 ) { if ( $MoonAngDiam000 >= 1758.24 ) { if ( $MoonAngDiam000 <= 1992.79 ) { if ( $MoonAzimuth007 >= 79.8481 ) { if ( $MoonAzimuth007 <= 143.336 ) { if ( $MoonElevation007 >= -14.6267 ) { if ( $MoonElevation007 <= 29.6536 ) { if ( $MoonIllumPct007 >= 48.171 ) { if ( $MoonIllumPct007 <= 99.651 ) { if ( $MoonAngDiam007 >= 1763.85 ) { if ( $MoonAngDiam007 <= 1935.73 ) { if ( $MoonIllumPct000 > $MoonIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $VenusAzimuth000 >= 179.041 ) { if ( $VenusAzimuth000 <= 270.048 ) { if ( $VenusElevation000 >= 16.6749 ) { if ( $VenusElevation000 <= 28.7977 ) { if ( $VenusIllumPct000 >= 86.292 ) { if ( $VenusIllumPct000 <= 99.985 ) { if ( $VenusAngDiam000 >= 9.61969 ) { if ( $VenusAngDiam000 <= 15.2557 ) { if ( $VenusAzimuth007 >= 236.824 ) { if ( $VenusAzimuth007 <= 272.992 ) { if ( $VenusElevation007 >= 16.8584 ) { if ( $VenusElevation007 <= 28.6785 ) { if ( $VenusIllumPct007 >= 18.945 ) { if ( $VenusIllumPct007 <= 99.891 ) { if ( $VenusAngDiam007 >= 9.70542 ) { if ( $VenusAngDiam007 <= 47.8982 ) { if ( $VenusIllumPct000 > $VenusIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $VenusAzimuth000 >= 176.408 ) { if ( $VenusAzimuth000 <= 269.877 ) { if ( $VenusElevation000 >= 1.9608 ) { if ( $VenusElevation000 <= 13.304 ) { if ( $VenusIllumPct000 >= 74.517 ) { if ( $VenusIllumPct000 <= 95.315 ) { if ( $VenusAngDiam000 >= 10.4481 ) { if ( $VenusAngDiam000 <= 21.8056 ) { if ( $VenusAzimuth007 >= 239.865 ) { if ( $VenusAzimuth007 <= 272.659 ) { if ( $VenusElevation007 >= 2.8772 ) { if ( $VenusElevation007 <= 29.0173 ) { if ( $VenusIllumPct007 >= 46.812 ) { if ( $VenusIllumPct007 <= 99.655 ) { if ( $VenusAngDiam007 >= 9.82985 ) { if ( $VenusAngDiam007 <= 15.5886 ) { if ( $VenusIllumPct000 > $VenusIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $MoonAzimuth000 >= 65.7005 ) { if ( $MoonAzimuth000 <= 114.018 ) { if ( $MoonElevation000 >= -24.4821 ) { if ( $MoonElevation000 <= 32.2454 ) { if ( $MoonIllumPct000 >= 19.643 ) { if ( $MoonIllumPct000 <= 98.531 ) { if ( $MoonAngDiam000 >= 1783.96 ) { if ( $MoonAngDiam000 <= 1970.11 ) { if ( $MoonAzimuth007 >= 112.542 ) { if ( $MoonAzimuth007 <= 228.046 ) { if ( $MoonElevation007 >= -4.9741 ) { if ( $MoonElevation007 <= 68.1649 ) { if ( $MoonIllumPct007 >= 2.534 ) { if ( $MoonIllumPct007 <= 71.343 ) { if ( $MoonAngDiam007 >= 1795.31 ) { if ( $MoonAngDiam007 <= 1979.96 ) { if ( $MoonIllumPct000 > $MoonIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $MoonAzimuth000 >= 8.0126 ) { if ( $MoonAzimuth000 <= 77.7495 ) { if ( $MoonElevation000 >= -54.0281 ) { if ( $MoonElevation000 <= 70.2897 ) { if ( $MoonIllumPct000 >= 88.009 ) { if ( $MoonIllumPct000 <= 99.839 ) { if ( $MoonAngDiam000 >= 1764.6 ) { if ( $MoonAngDiam000 <= 1993.24 ) { if ( $MoonAzimuth007 >= 66.4668 ) { if ( $MoonAzimuth007 <= 143.117 ) { if ( $MoonElevation007 >= -1.9771 ) { if ( $MoonElevation007 <= 37.2114 ) { if ( $MoonIllumPct007 >= 7.36 ) { if ( $MoonIllumPct007 <= 99.217 ) { if ( $MoonAngDiam007 >= 1764.82 ) { if ( $MoonAngDiam007 <= 1953.44 ) { if ( $MoonIllumPct000 > $MoonIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    if ( $VenusAzimuth000 >= 243.997 ) { if ( $VenusAzimuth000 <= 270.371 ) { if ( $VenusElevation000 >= -4.208 ) { if ( $VenusElevation000 <= 29.4658 ) { if ( $VenusIllumPct000 >= 70.215 ) { if ( $VenusIllumPct000 <= 99.563 ) { if ( $VenusAngDiam000 >= 9.7534 ) { if ( $VenusAngDiam000 <= 16.7935 ) { if ( $VenusAzimuth007 >= 245.968 ) { if ( $VenusAzimuth007 <= 274.164 ) { if ( $VenusElevation007 >= -13.188 ) { if ( $VenusElevation007 <= 28.8037 ) { if ( $VenusIllumPct007 >= 69.07 ) { if ( $VenusIllumPct007 <= 99.155 ) { if ( $VenusAngDiam007 >= 9.85254 ) { if ( $VenusAngDiam007 <= 15.9083 ) { if ( $VenusIllumPct000 > $VenusIllumPct007 ) { $return =   1 ; } } } } } } } } } } } } } } } } }
    
    The baseline combined 4985 simulated trades on the whole validation data had mean gain 0.29 percent, sample standard deviation 3.36 percent, median gain 0.67 percent, and winning percent 61.54. The goal was to get trading rules with better values than the baseline (higher gains, lower standard deviation, higher winning percent).

    The set of trading rules above using the validation data resulted in 2277 simulated trades with mean gain 0.63 percent, sample standard deviation 2.95 percent, median gain 0.90 percent, and winning percent 67.02. The trading rules from each of the 12 individual training runs also had better values than the baseline.

    Because the future inputs can be generated, future trades can be predicted. Here are the predicted trades using the above rules for the S&P 500 through the end of May.
    Code:
    endHistoryDate 20230330 startTradeDate 20230331 endTradeDate 20230417
    endHistoryDate 20230406 startTradeDate 20230410 endTradeDate 20230424
    endHistoryDate 20230426 startTradeDate 20230427 endTradeDate 20230511
    endHistoryDate 20230427 startTradeDate 20230428 endTradeDate 20230512
    endHistoryDate 20230428 startTradeDate 20230501 endTradeDate 20230515
    endHistoryDate 20230501 startTradeDate 20230502 endTradeDate 20230516
    endHistoryDate 20230502 startTradeDate 20230503 endTradeDate 20230517
    endHistoryDate 20230503 startTradeDate 20230504 endTradeDate 20230518
    endHistoryDate 20230504 startTradeDate 20230505 endTradeDate 20230519
    endHistoryDate 20230505 startTradeDate 20230508 endTradeDate 20230522
    
    The combination of predicted trades would be go long at the close March 31; exit at the close April 24. Go long at the close April 27; exit at the close May 22.
     
  2. athlonmank8 likes this.
  3. M.W.

    M.W.

    You could have as well fed your back test with buttermilk prices in Bangladesh. It's called curve fitting. The technical term is spurious correlation. Not a single asset price evolution correlates coherently with astronomical data over time. Even a broken clock though is correct twice a day. That's everything that needs to be said about this kind of data analysis.

    What most likely happened in your back test is that you correlated the trendiness of index prices especially of pricing data a long time before the Advent of trading algorithms with the trendiness of another time series. You get the same results with any other trending time series. This has nothing to do with any potential predictive power of astronomical data.


     
    Snuskpelle likes this.
  4. It is not totally crap. But the use is very limited and you cannot get fine trading strategies with them regarding to a good Sharpe Ratio here. For example if you look on Sun Spot Cycles they have a bigger influence on warm or cold climate so how much are the temperatures which then affect the commodities and their prices. And of course commodities also affect other markets. So here is a link to it.

    https://www.cxoadvisory.com/calendar-effects/does-the-sunspot-cycle-predict-energy-and-grain-prices/

    Does the Sunspot Cycle Predict Grain Prices?

    Steve LeCompte | December 14, 2018 | Calendar Effects, Commodity Futures

    As a follow-up to “Sunspot Cycle and Stock Market Returns” a reader asked: “Sunspot activity does have a direct relationship to weather. Could one speculate on the agriculture market using the sunspot cycle?” To investigate, we relate sunspot activity to the fairly long U.S. Producer Price Index (PPI) for grains. Using monthly averages of daily sunspot counts and monthly PPI for grains during January 1926 (limited by PPI data) through October 2018, we find that:

    The National Weather Service notes:

    “There is debate within the scientific community how much solar activity can, or does affect Earth’s climate. There is research which shows evidence that Earth’s climate is sensitive to very weak changes in the Sun’s energy output over time frames of 10s and 100s of years. Times of maximum sunspot activity are associated with a very slight increase in the energy output from the sun. Ultraviolet radiation increases dramatically during high sunspot activity, which can have a large effect on the Earth’s atmosphere. The converse is true during minimum sunspot activity. But trying to filter the influence of the Sun’s energy output and its effect on our climate with the ‘noise’ created by a complex interaction between our atmosphere, land and oceans can be difficult.”

    If there is a sunspot activity-weather relationship, we hypothesize that a high sunspot count (warm weather) would depress grain prices (support good crops).

    The following chart plots monthly sunspot activity and grains PPI, with the latter on a logarithmic scale. There are about nine 11-year sunspot cycles in the full sample, with the peak at the end of the 1950s strongest and the most recent peak the weakest. Visual inspection reveals no obvious relationship between the two series.

    The sunspot series appears to have a reasonably stable average (95.0 for this sample), while the grains PPI series does not. We therefore proceed by relating monthly sunspot activity to monthly change in grains PPI. Because investors know that the sunspot cycle is predictable, we can use coincident data.

    [​IMG]

    The following scatter plot relates monthly change in grains PPI to monthly sunspot activity over the full sample period. The Pearson correlation for the two series is -0.03 and the R-squared statistic is 0.00, indicating that variation in monthly sunspot activity explains none of monthly variation in grains PPI.

    In case sunspot effects are longer-term, we look at annual data.

    [​IMG]

    The next scatter plot relates annual change in grains PPI to annual sunspot activity (average of monthly activity during the year) over the full sample period. The Pearson correlation for these two series is -0.07 and the R-squared statistic is 0.01, indicating that annual sunspot activity may have a slightly negative relationship to annual change in grains PPI (very weakly supporting the hypothesis).

    In case the relationship is materially non-linear, we look at average annual change in grains PPI by ranked third (tercile) of annual sunspot activity.

    [​IMG]

    The next chart summarizes average annual changes in grains PPI by tercile of annual sunspot activity over the full sample period. There are 30 observations per tercile. Results suggest that low and moderate sunspot activity is better for grain prices than high sunspot activity, supporting the hypothesis that grains are less plentiful for those conditions. However, tercile subsamples are small, and the relationship is not systematic across terciles, so findings are not very reliable.

    Might sunspot activity and change in grains PPI interact with a lag?

    [​IMG]

    The final chart summarizes correlations for various lead-lag relationships between annual sunspot activity and annual change in grains PPI over the full sample period, ranging from change in grains PPI leads sunspot activity by 11 years (-11) to sunspot activity leads change in grains PPI by 11 years (11). Notable points are:

    • Grains may interact very weakly with sunspot activity on a long cycle, with peaks in correlations about 11 years apart.
    • The coincident relationship, as found above, is slightly negative. This negative correlation persists for sunspot activity leading change in grains PPI by one and two years.
    • The left peak suggests that change in grains PPI leads sunspot activity with positive correlations by six to seven years. However, this peak is very weak.
    • The right peak suggests that sunspot activity leads change in grains PPI by four to six years.
    There may be some underlying agricultural explanation for correlation dips and peaks, but not an obvious one. Given the very small number of solar cycles and bull-bear grain cycles in the sample, the peaks may be just noise.

    [​IMG]

    In summary, evidence from simple tests on available data offers very little support for use of sunspot activity as a grains commodity timing tool, with slight indication that high sunspot activity puts downward pressure on price.

    Cautions regarding findings include:

    • As noted, there are only about nine sunspot cycles during the sample period, so overall findings are not very reliable. Also as noted, the number of observations in the tercile subsamples is small, such that a few outliers materially affect the average tercile changes in grains PPI.
    • All analyses are in-sample. An investor operating in real time based only on past data may have drawn different conclusions at different times.

    http://www.timingsolution.com/TS/Articles/sunspot/

    https://www.visualcapitalist.com/what-is-a-commodity-super-cycle/

    What is a Commodity Super Cycle?
    [​IMG]


    Published

    4 years ago
    on

    August 2, 2019
    By

    Nicholas LePan

    [​IMG]

    Visualizing the Commodity Super Cycle
    Since the beginning of the Industrial Revolution, the world has seen its population and the need for natural resources boom.

    As more people and wealth translate into the demand for global goods, the prices of commodities—such as energy, agriculture, livestock, and metals—have often followed in sync.

    This cycle, which tends to coincide with extended periods of industrialization and modernization, helps in telling a story of human development.

    Why are Commodity Prices Cyclical?
    Commodity prices go through extended periods during which prices are well above or below their long-term price trend. There are two types of swings in commodity prices: upswings and downswings.

    Many economists believe that the upswing phase in super cycles results from a lag between unexpected, persistent, and positive trends to support commodity demand with slow-moving supply, such as the building of a new mine or planting a new crop. Eventually, as adequate supply becomes available and demand growth slows, the cycle enters a downswing phase.

    While individual commodity groups have their own price patterns, when charted together they form extended periods of price trends known as “Commodity Super Cycles” where there is a recognizable pattern across major commodity groups.

    How can a Commodity Super Cycle be Identified?
    Commodity super cycles are different from immediate supply disruptions; high or low prices persist over time.

    In our above chart, we used data from the Bank of Canada, who leveraged a statistical technique called an asymmetric band pass filter. This is a calculation that can identify the patterns or frequencies of events in sets of data.

    Economists at the Bank of Canada employed this technique using their Commodity Price Index (BCPI) to search for evidence of super cycles. This is an index of the spot or transaction prices in U.S. dollars of 26 commodities produced in Canada and sold to world markets.

    • Energy: Coal, Oil, Natural Gas
    • Metals and Minerals: Gold, Silver, Nickel, Copper, Aluminum, Zinc, Potash, Lead, Iron
    • Forestry: Pulp, Lumber, Newsprint
    • Agriculture: Potatoes, Cattle, Hogs, Wheat, Barley, Canola, Corn
    • Fisheries: Finfish, Shellfish
    Using the band pass filter and the BCPI data, the chart indicates that there are four distinct commodity price super cycles since 1899.

    • 1899-1932:
      The first cycle coincides with the industrialization of the United States in the late 19th century.
    • 1933-1961:
      The second began with the onset of global rearmament before the Second World War in the 1930s.
    • 1962-1995:
      The third began with the reindustrialization of Europe and Japan in the late 1950s and early 1960s.
    • 1996 – Present:
      The fourth began in the mid to late 1990s with the rapid industrialization of China
    What Causes Commodity Cycles?
    The rapid industrialization and growth of a nation or region are the main drivers of these commodity super cycles.

    From the rapid industrialization of America emerging as a world power at the beginning of the 20th century, to the ascent of China at the beginning of the 21st century, these historical periods of growth and industrialization drive new demand for commodities.

    Because there is often a lag in supply coming online, prices have nowhere to go but above long-term trend lines. Then, prices cannot subside until supply is overshot, or growth slows down.

    Is This the Beginning of a New Super Cycle?
    The evidence suggests that human industrialization drives commodity prices into cycles. However, past growth was asymmetric around the world with different countries taking the lion’s share of commodities at different times.

    With more and more parts of the world experiencing growth simultaneously, demand for commodities is not isolated to a few nations.

    Confined to Earth, we could possibly be entering an era where commodities could perpetually be scarce and valuable, breaking the cycles and giving power to nations with the greatest access to resources.

    Each commodity has its own story, but together, they show the arc of human development.

    ------------------

    https://socionomics.net/2011/09/article-the-sunspot-cycle-and-stocks/

    [Article] The Sunspot Cycle and Stocks
    ARTICLE, ELLIOTT WAVE THEORIST, PETE KENDALL, ROBERT PRECHTER, SCIENCE
    [​IMG]
    By Robert R. Prechter, Jr. and Peter Kendall, originally published in the September 2000 Elliott Wave Theorist.


    In the early 1930s, statisticians Felix Shaffner and Carlos Garcia-Mata set out to refute economic theories (by W. Stanley Jevons in 1867 and others) suggesting a correlation between the 10.3-year sunspot cycle1 and changes in agricultural and business activity. They commented, “Indeed this evidence was so striking that we thought it necessary to conduct further investigations to prove the resemblance accidental. In this we were unsuccessful.” Their research appeared in the November 1934 Quarterly Journal of Economics. Based on a study of five sunspot cycles back through 1875, Shaffner and Garcia-Mata found that industrial production repeatedly peaked before the number of sunspots did. With respect to the stock market, they also looked at the turns in 1929 and 1932 and found a high degree of correlation. Charles Collins, R.N. Elliott’s original Wall Street benefactor and one of the great stock market students of the time, extended the stock market correlation with a longer-term analysis in the 1960s. Collins related 93 years of sunspot data to the trends of U.S. stocks over the same span and concurred that important stock market peaks consistently precede sunspot cycle maximums. His findings, “An Inquiry into the Effect of Sunspot Activity on the Stock Market,” appeared in the November-December 1965 issue of the Financial Analysts Journal. By anticipating the eventual peak in the sunspot cycle, Collins asserted that investors could avoid the most serious stock market declines.

    [​IMG]
    Figure 1

    Sunspot counts range from a low of near 0 at the bottom of the cycle to 100 to 200 at their peak. One of the final contributions of Collins’ long career as an investment counselor and writer was the following early warning signal: “An important stock market peak has been witnessed or directly anticipated when, in the course of each new sunspot cycle, the yearly mean of observed sunspot numbers has climbed above 50.” Once the annual mean climbs above 50, Collins added, the largest percentage decline of the stock market cycle usually follows. Based on a 1964 bottom in the sunspot cycle, Collins speculated that 1967 would bring the count above 50 and thus indicate trouble ahead for the market. The threshold was, in fact, breached in 1967, which was fair warning of the speculative peak in 1968. In 1978, Collins’ sunspot indicator marked another important high that was followed by a sideways market over the next four years (which was a decline in PPI-adjusted terms). The next signal came in May 1988. The 1987 crash had already occurred, so the warning was late. However, stocks had a second selloff in 1990 that brought the Value Line index back to its 1987 low (see Figure 2 on page 3), so the sunspot threshold did signal a period of relative weakness. Despite minor anomalies, then, Collins’ observations have remained applicable. Figure 1 shows the history of the sunspot count, the stock market and those recessions most closely associated with sunspot maximums.

    The current sunspot cycle began in October 1996 and appears to be adhering closely to the typical pattern. In the first two years of the cycle, the Dow Jones Industrial Average did not experience any significant stock market corrections as it gained 32%, slightly below the century-long average of 37% for this phase of the sunspot cycle. The annual sunspot mean of 50 was reached in 1998. Considering the succession of peaks in all the major market indicators and indexes, from the advance/decline line in April 1998 to the NASDAQ in March 2000 (see chart in the July 2000 Elliott Wave Financial Forecast), the sunspots and the market appear once again to be very much in line with historical observations. Once Collins’ fair-warning sunspot signal has been given, the market may go to new highs, but it has entered a window of vulnerability that has been followed by stock market weakness in every instance over the course of the 20th century. The end of the time zone for a market top is just before the maximum monthly sunspot number, which is shown as a dashed line in the chart. Sunspot maximums have come 1 to 15 months after peaks in stocks. The average is 8 months. According to solar scientists, the next peak is due in December 2000, which matches the average duration over the last century. The declines that commenced in January (DJIA) and March (NDQ) 2000, then, are within the window for a turn. At this point, the stock market’s decline almost certainly has further to go because a two-month loss of 17% (to early March low) would be shorter in time than any corresponding decline and shallower than all but that of 1978, when stock prices were already depressed.

    Stock market weakness associated with sunspot maximum tends to run several years, averaging 4 years and 4 months. In terms of return, the least bearish event (see table, page 2) was that of cycle 6 in the 1950s and early 1960s, when the Dow edged out a gain of 1.5 points over a period of almost 6 years. How much decline should we expect this time? The largest bear markets have come off sunspot maximums that are below the prior maximum. As you can see in Figure 2, the current sunspot cycle is doing exactly that. As with the sunspot cycles associated with the market highs in 1929 and 1968, which were followed by the two biggest bear markets of the century, the current sunspot cycle is topping out at a lower level than that of 1990. The recent bunching of the monthly sunspot count and the already-registered peak in the rate of change (see Figure 4) suggest a lower maximum sunspot in this cycle.

    [​IMG]
    Figure 2

    Outlook for the Economy

    Links between sunspots and economic activity have been documented as far back as the 1720s. The shaded areas in Figure 1 show that every sunspot maximum this century has had a corresponding recession. In most cases, the recession begins when sunspots peak, which is after the top in the stock market. Only in 1938 and 1946 did the closest recession precede the sunspot maximum, but in the latter case, a second one occurred in 1948-49, roughly at the normal time. At this point in the current cycle, sunspots are approaching a peak, and a bear market in stocks is developing. The century of history shown here says unequivocally that today’s economy should be heading into the early stages of a recession or depression within a matter of months.

    The stock market has never bottomed in this progression until a recession occurs. Thus, another reason to expect today’s new bear market to continue is that there has been no recession.

    Generally speaking, the periods from immediately before to immediately after each sunspot cycle maximum account for almost all of the major financial disruptions of the last century. In addition to the average of 4.4 years of stock market weakness, a sunspot cycle maximum and subsequent decline is generally followed by a financial crisis and another recession. At the beginning of the century, there was also a third recession at the sunspot lows.

    Timing the Next Major Market Bottom

    By the time of the sunspot cycle minimum, the most severe turmoil for stocks and the economy is almost always past. In fact, buying opportunities have presented themselves ahead of the minimum point in every cycle since 1910. The dotted lines in Figure 3 show the same relative position of the sunspot frequency at important market bottoms. These bottoms, which include the start of Supercycle ) in 1932, Cycle III in 1942 and Cycle V in 1974, occurred when the rate of change in monthly sunspot counts decelerated to an average of 26.5% of its prior level (using a four-month moving average to smooth sunspot volatility). This bottom is due next in July 2004. Based on an average market effect of 4.4 down years, the current stock-market contraction should see a preliminary low in the first half of 2004. These dates fit The Elliott Wave Theorist’s cycle and Fibonacci studies calling for a bottom in 2003-2004 (see July issue). Given the potential, this headline from the July 17 USA Today strikes us as optimistic:

    Solar Storm’s Disruptions Mostly Over
    More than likely, the disruptions have just begun, at least in the social sense.

    [​IMG]

    A Broader Application?

    Some effects from solar radiation are well documented. Sunspots disrupt satellite systems, radio transmissions and electric power grids. In the realm of mass human activity, the sun’s role has been a source of speculation since the dawn of civilization. In 1926, Professor A. C. Tchijevsky traced the sunspot activity back through 500 B.C. and found that it produced nine waves of human excitability per century. “As sunspot activity approaches maximum,” Tchijevsky found, “the number of mass historical events taken as whole increases.” Part II of The Wave Principle of Human Social Behavior describes the basis of the Wave Principle and unconscious human herding behavior as a function of the human limbic system, which is the gatekeeper of emotion within the human brain. However, the limbic system is not necessarily independent of outside forces. As the radiating center of our solar system and the wellspring of practically all the energy on the planet, the sun is certainly an intriguing contender for some degree of external mass mental influence.

    Why does the stock market typically peak before sunspots do? One very plausible explanation is that the collective tendency to speculate peaks out along with the rate of change in sunspot activity. If sunspots affect humans’ positive-mood excitability, that appears to be the point of maximum effect.

    [​IMG]
    Figure 4

    When we explored this possible explanation, we found something additionally interesting. Figure 4 shows that as the solar radiation thrown off by the sun increases to a maximum rate (shown by our optimized 39-month rate of change in sunspot numbers), the human urge to speculate in general hits a fever pitch. Two months after the rate-of-change peak in 1916, the stock market established an all-time high that was not materially exceeded until the sunspot count was accelerating again in the mid-1920s. The next rate-of-change peak in October 1926 preceded the final stock market high by a full three years, but the speculative fever that accompanied the Florida land boom ended almost coincidentally, about two months earlier. The next peak was a double top that finished in February 1937, one month before a major stock market high. In 1947 and 1967, the rate of change peaked within 13 months of major stock peaks. In 1957, the peak coincided with with the all-time high in the advance-decline line, which stands to this day. The September 1979 peak was four months before a century-long high in precious metals prices. The August 1989 peak accompanied the all-time high in the Nikkei and the end of a big real estate boom in California and Japan. Since scientists’ grasp of the sunspot cycle is based on empirical observation rather than an understanding of what causes it, there is no way to verify that a rising rate of sunspot activity is behind these outbreaks. However, the speculative fall-off in the wake of every peak since 1916 is itself strong evidence of an effect. The latest peak rate of change came in December 1999, and that sets up a test. Will this peak in sunspots mark the end of the greatest mania in the history of the stock market? So far, the answer is “yes,” as the Dow topped a month later and the more speculative NASDAQ peaked in March. A ninth straight correspondence will not prove the case, but it will add to the empirical evidence.■

    [​IMG]

    Notes

    1 10.3 years is the average duration of the sunspot cycle in the 20th Century. From the mid-18th through the 19th century, the cycle was 11.7 years (peak to peak)

    [​IMG]
    The Socionomist is a monthly online magazine designed to help readers see and capitalize on the waves of social mood that contantly occur throughout the world. It is published by the Socionomics Institute, Robert R. Prechter, president; Matt Lampert, editor-in-chief; Alyssa Hayden, editor; Alan Hall and Chuck Thompson, staff writers; Dave Allman and Pete Kendall, editorial direction; Chuck Thompson, production; Ben Hall, proofreader.

    -------
    https://www.sciencedirect.com/science/article/abs/pii/0304406895007512

    https://www.jstor.org/stable/2297716

     
    Last edited: Mar 26, 2023
    Sprout likes this.
  5. mikeriley

    mikeriley

    Sprout and MACD like this.
  6. tomkat22

    tomkat22

    Even a New Orleans Voodoo Queen would be envious of that voodoo nonsense.
     
  7. zdreg

    zdreg

    The greater the inflation rate the more voodoo economics will be heard from.
     
  8. ph1l

    ph1l

    I never claimed astronomical data or the objects behind the data cause market changes, so it's not spurious correlation by definition.

    For the 12 independently-created rules tested on almost 20 years of out-of-sample data, each one of them had better results (returns, standard deviation, winning percent) than the simulated trades using all the out-of-sample data.

    So is this 12 stopped clocks working for 20 years, or is your argument it doesn't make sense to you that successful trading rules for an asset can be created from data independent of the asset?

    FYI, it's butter in Bangladesh, not buttermilk.:)
     
  9. M.W.

    M.W.

    That's not spurious correlation. It is a claimed relationship between data where there is no causal relationship. And good luck putting any trust into an algorithm that rests on completely illogical relationships. It makes zero sense and bestows zero confidence should you hit a drawdown. Are you honestly suggesting those relationships have not been rested and immediately refuted by hundreds of professionals?

     
  10. ph1l

    ph1l

    So we agree it's not spurious correlation, and I presented a predictive model and not a causal model.

    I understand how the cyclical nature of markets might not make sense to everyone, but your appeal to authority fallacy ("rested and immediately refuted by hundreds of professionals") isn't much of an argument.
     
    #10     Mar 27, 2023