Store the price in a variable at which I entered the position - futures io
futures io



Store the price in a variable at which I entered the position


Discussion in TradeStation

Updated
      Top Posters
    1. looks_one mattjack9708 with 2 posts (0 thanks)
    2. looks_two numberjuani with 1 posts (0 thanks)
    3. looks_3 ABCTG with 1 posts (0 thanks)
    4. looks_4 andyprm70 with 1 posts (0 thanks)
    1. trending_up 1,015 views
    2. thumb_up 0 thanks given
    3. group 3 followers
    1. forum 4 posts
    2. attach_file 0 attachments




Welcome to futures io: the largest futures trading community on the planet, with well over 125,000 members
  • Genuine reviews from real traders, not fake reviews from stealth vendors
  • Quality education from leading professional traders
  • We are a friendly, helpful, and positive community
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts
  • We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

(If you already have an account, login at the top of the page)

 
Search this Thread
 

Store the price in a variable at which I entered the position

(login for full post details)
  #1 (permalink)
andyprm70
Princeton NJ, UNITED STATES
 
 
Posts: 1 since May 2019
Thanks: 0 given, 0 received

I am super new to trading and easylanguage. About 3 months new. Into IT for 20+ years. understand programming.

I am trying to figure out the following:
1. If I am performing a "Buy next bar at Low+1Point + Higher;" how do I store this price at which I bought the contract? any sample code I can look for?

2. Is there any way I can Buy not at a "Next Bar" but lets say after 50 ticks? what will be the code or this cannot be done?

Currently I am trading on Canadian Futures.

Reply With Quote

Journal Challenge April 2021 results (now extended!):
Competing for $1800 in prizes from Jigsaw
looks_oneMaking a Living with the Microsby sstheo
(353 thanks from 34 posts)
looks_twoSalao's Journalby Salao
(81 thanks from 13 posts)
looks_3Learning to Profit - A journey in algorithms and optionsby Syntax
(58 thanks from 17 posts)
looks_4Deetee’s DAX Trading Journal (time based)by Deetee
(51 thanks from 22 posts)
looks_5Maybe a little bit different journalby Malykubo
(37 thanks from 20 posts)
 
Best Threads (Most Thanked)
in the last 7 days on futures io
The Crude Dude Oil Trading System
113 thanks
Help improve the FIO community
38 thanks
futures io site changelog and issues/problem reporting
24 thanks
Next New Poll Ideas/Suggestions
20 thanks
www.isystems.com
17 thanks
 
(login for full post details)
  #2 (permalink)
 ABCTG   is a Vendor
 
 
Posts: 2,239 since Apr 2013
Thanks: 417 given, 1,490 received

andyprm70,

you could for example use the reserved word EntryPrice to retrieve the fill price of an entry.

Depending on what you mean with "after 50 ticks" you could look into using a stop order for the entry at a specific price above the current market for a long.

Regards,

ABCTG



andyprm70 View Post
I am super new to trading and easylanguage. About 3 months new. Into IT for 20+ years. understand programming.

I am trying to figure out the following:
1. If I am performing a "Buy next bar at Low+1Point + Higher;" how do I store this price at which I bought the contract? any sample code I can look for?

2. Is there any way I can Buy not at a "Next Bar" but lets say after 50 ticks? what will be the code or this cannot be done?

Currently I am trading on Canadian Futures.


Follow me on Twitter Reply With Quote
 
(login for full post details)
  #3 (permalink)
 numberjuani 
Agoura Hills, CA USA
 
Experience: Advanced
Platform: Tradestation&Multicharts
Broker: TradeStation
Trading: Futures & Equities
 
numberjuani's Avatar
 
Posts: 127 since Apr 2019
Thanks: 9 given, 98 received



andyprm70 View Post
I am super new to trading and easylanguage. About 3 months new. Into IT for 20+ years. understand programming.

I am trying to figure out the following:
1. If I am performing a "Buy next bar at Low+1Point + Higher;" how do I store this price at which I bought the contract? any sample code I can look for?

2. Is there any way I can Buy not at a "Next Bar" but lets say after 50 ticks? what will be the code or this cannot be done?

Currently I am trading on Canadian Futures.

HI Andy,

So theres the reserved word "EntryPrice", that you can refer later, like "Sell Next Bar at EntryPrice + 50", also, for your specific points:
#1: if you mean to buy one point above the Low, then that would be "Buy Next Bar at L+1 Limit". When youre buying below price you use Limit which means "this price or better" and when youre buying above price you use "stop" which means this price or worse. Also, "EntryPrice" will automatically know where you entered.
#2: 50 ticks after what? as soon as you make ticks part of your code the backtest will only be good for 6 months, because thats how much data TS stores for tick. Having said that the best way to do that would be to be in a tick chart, make your conditions a true false, and then check fifty bars ago. Example:
Variables:
Conditions(False);

Conditions = RSI > 30 and C < O

if Conditions[50] then buy next bar market;

Sound good?

Reply With Quote
 
(login for full post details)
  #4 (permalink)
mattjack9708
Wisconsin
 
 
Posts: 28 since Sep 2019
Thanks: 8 given, 7 received


andyprm70 View Post
I am super new to trading and easylanguage. About 3 months new. Into IT for 20+ years. understand programming.

I am trying to figure out the following:
1. If I am performing a "Buy next bar at Low+1Point + Higher;" how do I store this price at which I bought the contract? any sample code I can look for?

2. Is there any way I can Buy not at a "Next Bar" but lets say after 50 ticks? what will be the code or this cannot be done?

Currently I am trading on Canadian Futures.

Are you working on algorithmic trading at the moment?

Reply With Quote
 
(login for full post details)
  #5 (permalink)
mattjack9708
Wisconsin
 
 
Posts: 28 since Sep 2019
Thanks: 8 given, 7 received


mattjack9708 View Post
Are you working on algorithmic trading at the moment?

I am new trader here as well, but working on discretionary trading.

Reply With Quote


futures io Trading Community Platforms and Indicators TradeStation > Store the price in a variable at which I entered the position


Last Updated on September 2, 2019


Upcoming Webinars and Events
 

NinjaTrader Indicator Challenge!

Ongoing
 

Journal Challenge w/$1,800 in prizes!

April

An Introduction to CME Group Micro Bitcoin Futures w/David Lerman

Elite only
     



Copyright © 2021 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada), info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts