BATS:SPY   SPDR S&P 500 ETF TRUST
This Pinefest was closed October 28 2023. Congratulations to its winner, alexgrover with this script.


█ CHALLENGE

Create three functions that will return the exact value where two data series intersect:
crossValue(source1, source2) 
crossoverValue(source1, source2) 
crossunderValue(source1, source2)
When a cross occurs, the functions must return the intersection's value. When no cross occurs, they must return na.


█ SUBMISSIONS

Prepare your entry as a private open-source script publication, including a detailed description explaining to its audience how it works and can be useful, just like public scripts published in Community Scripts. Your private publication must comply with our Script Publishing Rules.

Submit your entry as a comment in the Comments section below, with a link to your private publication. This way, all TradingViewers can view submissions. Note that publishing links to private publications is against House Rules; we make an exception for our Pinefest submissions.

No public script publications will be accepted as entries. Participants who publish their entries publicly will be disqualified, and their publication will be hidden. Entries must be your own work. Calls to functions of previously published libraries (by you or others) are allowed, as is the use of a private library accompanying your entry.

You have one week to submit your entry. Submission deadline: 28 Oct 2023, 12:00 UTC
If you have questions about this Pinefest, please post a comment below.


█ EVALUATION CRITERIA

A PineCoders committee will evaluate all submissions based on the following criteria:
 • Submission date
 • Solution to the challenge
 • Code efficiency
 • Code readability
 • Description
 • Visuals
 • Script usability
 • Compliance with our Script Publishing Rules
In case two or more publications reach an identical final evaluation, the earliest submission will win. Committee​ decisions are final.


█ REWARDS

The winner of this Pinefest will receive 500 USD and publish their script publicly in our Community Scripts. Their publication will also be awarded an Editors' Pick, for which the winner will receive an additional 100 USD. Authors of the five highest-scoring submissions will be awarded TradingView merchandise.

Tools and ideas for all Pine coders: www.pinecoders.com
Our Pine FAQ & Code: www.pinecoders.com/faq_and_code/
Pine news broadcasts: t.me/PineCodersSquawkBox or twitter.com/PineCoders

Related Ideas

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.