React + TypeScript Assignment
React + TypeScript Assignment
Problem Statement:
Trading Studio is an online platform that allows users to create trading/investment strategies and backtest their performance
on historical data. Users can perform the following actions on the platform:
Strategy Structure
● Scanner step
○ The goal of this step is to identify all financial instruments that meet a certain set of scanner rules on a given day.
● Buy step
○ The goal of this step is to identify all financial instruments that meet a certain set of buy-trigger rules on a given
day.
● Sell step
○ The goal of this step is to identify all financial instruments that meet a certain set of sell-trigger rules after being
shortlisted in the buy step.
● Simulation step
○ The goal of this step is to simulate the portfolio using a given portfolio configuration, based on the items
shortlisted in the above steps.
Example:
SAMPLE SCANNER-STEP-CONFIG RULE:
exchange = NSE
AND
instrument_type = EQUITY
AND
(
(
last 300 days price growth is greater than 0%
AND
price of the instrument is greater than 99
)
OR
(
instrument is among the top 10% instruments when ranked by market capitalisati
AND
instrument's 90 day average daily transaction value is greater than 300000000
)
)
Explanation of scanner rule: This rule ensures that only instruments of type EQUITY from NSE are included in the strategy.
Additionally, on any given day, only those instruments are filtered whose: (last 300 days price growth is greater than 0% AND
price of the instrument is greater than 99), OR (the instrument is among the top 10% instruments when ranked by market
capitalisation AND instrument's 90 day average daily transaction value is greater than 300000000)
SAMPLE BUY-STEP-CONFIG:
Explanation of buy rule: For a given day, from all the shortlisted instruments after the scanner step, only instruments whose:
(last price is greater than or equal to last 30 day close AND last price is greater than or equal to last 30 day moving average)
are shortlisted for entry.
SAMPLE SELL-STEP-CONFIG:
trailing_stoploss = 10%
AND
hold positions for at least 5 days
Explanation of sell rule: This sell rule defines that open positions will not be exited before 5 days from entry, and they will be
exited if trailing stoploss crosses 10%.
SAMPLE SIMULATION-STEP-CONFIG:
start_margin = 100000
AND
simulation_start_date = '01/01/2000'
AND
simulation_end_date = '20/03/2025'
AND
max_positions = 20
AND
max_positions_per_instrument = 1
AND
order_sorting_type = 300-days-top-gainer-first
Explanation of simulation rule: This rule defines that:
Notes:
This example is only intended to increase your understanding. You are NOT required to implement the simulator backend or
any backend/database-related features. Your task is to create the frontend web page(s) for this platform using React +
TypeScript.
Evaluation Criteria:
This assignment is expected to take 4-6 hours based on your current familiarity with React + TypeScript. You are not expected
to implement all user workflows. Pick 1 or 2 workflows which will allow you to demonstrate your skills in the best way. Your
submission will be evaluated on the following areas:
Submission:
● Push your code to any cloud git repository (example - GitHub) and either add '[email protected]' to that
repository or make the repository public
● Add a README file with instructions on how to run your app locally
● Mention any assumptions you have made
● Specify any other relevant information that you think will be useful
● Send an email to [email protected] when you have completed the assignment