NexusFi: Find Your Edge


Home Menu

 





VSA for ThinkorSwim


Discussion in ThinkOrSwim

Updated
      Top Posters
    1. looks_one snowcloud with 93 posts (25 thanks)
    2. looks_two StockJock with 91 posts (27 thanks)
    3. looks_3 cbritton with 37 posts (71 thanks)
    4. looks_4 swimtrader with 22 posts (19 thanks)
      Best Posters
    1. looks_one Hornblower with 2.3 thanks per post
    2. looks_two cbritton with 1.9 thanks per post
    3. looks_3 StockJock with 0.3 thanks per post
    4. looks_4 snowcloud with 0.3 thanks per post
    1. trending_up 310,135 views
    2. thumb_up 223 thanks given
    3. group 86 followers
    1. forum 434 posts
    2. attach_file 131 attachments




 
Search this Thread

VSA for ThinkorSwim

  #371 (permalink)
LivingLife9999
San Diego
 
Posts: 1 since Apr 2012
Thanks Given: 0
Thanks Received: 0


Massive l View Post
VPAv1_08.ts is the most recent and updated script

reattaching the script here. It's in this thread as well.


this appears to be a video file. I assume the file type association is wrong on my computer.

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Quant vue
Trading Reviews and Vendors
REcommedations for programming help
Sierra Chart
Better Renko Gaps
The Elite Circle
Cheap historycal L1 data for stocks
Stocks and ETFs
How to apply profiles
Traders Hideout
 
  #372 (permalink)
Hornblower
Oxnard California
 
Posts: 10 since Aug 2012
Thanks Given: 2
Thanks Received: 23

The .TS extension is either a video file extension of the extension assigned to thinkscript code files.

When you go to the TOS platform and click on studies you will notice a box that has import or export functions. Select import and the file.ts file that you want to import into the study section. When it gets into the editor it will tell you if you have an errors to be corrected. Those errors will be highlighted. When corrected the highlighting will disappear and you should be able to run the study.

A tremendous amount of effort went to the latest VSA study. I have just gone on line at Big Mikes' and am impressed with the blogs and attachments. Much work has been done with a lot of background information about VSA.

You can go thru the blogs for attachments that will help you. If you can tell me what you need I may have the file. I also have created several scanners that will pick up either the no demand or no supply indicator. I have attached the "Green Arrow" that stands for "Green UpArrow - Strength Confirmation Bar" scanner.

For VSA to get a high probability setup you need three VSA indicators and using Support/Resistance Levels to aid in the trade. That is based several books on the subject stated. I have done no trades yet.

Attached is the latest version of the VSA TOS version along with background information on VSA..

VPAv1_08STUDY.ts

VSA for ThinkorSwim-traderguide-indicators-v1.01.pdf

VSA for ThinkorSwim-vsa_system_explained.pdf

Reply With Quote
  #373 (permalink)
kunevn
Ho Chi Minh HCMC/Vietnam
 
Posts: 5 since May 2012
Thanks Given: 3
Thanks Received: 1


Hello! Please add label for the last bar also...many thank!

Reply With Quote
  #374 (permalink)
Hornblower
Oxnard California
 
Posts: 10 since Aug 2012
Thanks Given: 2
Thanks Received: 23

I am not sure what you mean by label.

I am aware that I did not include the coding for the scanning for VSA "Green Arrow" . So I am including it now.

# Arguments

input volumeEMALength = 30;
input narrowSpreadFactor = 0.7;
input wideSpreadFactor = 1.5;
input aboveAvgVolfactor = 1.5;

#######
# Calculations

rec spread = high - low;
def median = (high + low ) / 2;
rec avgVolume = compoundValue(volumeEMALength, ExpAverage(volume,
volumeEMALength), Double.NaN);

# Calculate Volume moving average and it's standard deviation
rec sAvgVolume = compoundValue(volumeEMALength, Average(volume,
volumeEMALength), Double.NaN);
def sAvgVolumeSTD = stdev(sAvgVolume, volumeEMALength);

# check if the vloume has been decreasing in the past two days.
def isTwoDaysLowVol = (volume < volume[1] && volume[0] < volume[2]);

# Calculate Range information
def avgSpread = WildersAverage(spread, volumeEMALength)[0];
rec isWideSpreadBar = (spread > (wideSpreadFactor * avgSpread));
rec isNarrowSpreadBar = (spread < (narrowSpreadFactor * avgSpread));





# Check if the close is in the Highs/Lows/Middle of the bar.
# C_RP 20100809
# original code - def x1 = if (close == low) then avgSpread else (spread /(close - low));
def x1 = if (high == low) then 2.0 else if (close == low) then 2.65 else (spread /
(close - low));
# C_RP try the line below with various divisors totalSum result in a minimum of 2.3 on a spread of 1 pip instead of using a fixed 2.3 as in the line above
# def x1 = if (high==low) then 2.0 else if (close == low) then (spread / 0.43 ) else (spread / (close - low));

# Price information
rec isUpBar = close > close[1];
rec isDownBar = close < close[1];
def isUpCloseBar = (x1 < 2);
def isDownCloseBar = (x1 > 2);
def isMidCloseBar = (x1 < 2.2 && x1 > 1.8);
def isVeryHighCloseBar = (x1 < 1.35);
# C_RP 20100809 added isVeryLowCloseBar
def isVeryLowCloseBar = (x1 >= 2.65);


# Trend Definitions

rec fiveDaysSma = compoundValue(5, Average(close, 5)[0], Double.NaN);
def LongTermTrendSlope = LinearRegressionSlope(price = fiveDaysSma, length =
40)[0];
def ShortTermTrendSlope = LinearRegressionSlope(price = fiveDaysSma, length =
5)[0];
def MiddleTermTrendSlope = LinearRegressionSlope(price = fiveDaysSma, length =
15)[0];

# stdn, stdn0, stdn1, stdn2
def strengthInDownTrend = (volume[0] > volume[1] && isDownBar[1] && isUpBar[0]
&& (isUpCloseBar or isMidCloseBar) && ShortTermTrendSlope < 0 &&
MiddleTermTrendSlope < 0);

def strengthInDownTrend1 = (volume[0] > (sAvgVolume[0] * aboveAvgVolfactor) &&
isDownBar[1] && isUpBar[0] && (isUpCloseBar or isMidCloseBar) &&
ShortTermTrendSlope < 0 && MiddleTermTrendSlope < 0 && LongTermTrendSlope < 0);
def strengthInDownTrend2 = (volume[1] < sAvgVolume[0] && isUpBar[0] &&
isVeryHighCloseBar && volume[0] > sAvgVolume[0] && ShortTermTrendSlope < 0);


rec bycond1 = (strengthInDownTrend or strengthInDownTrend1);
# bycond


def isStrengthConfirmationBar = (isUpBar[0] && bycond1[1]);

# bycond2 C_RP UpClose on higher volume with all slopes down adds extra strength
def isStrengthConfirmationBar2 = (isUpBar[0] && isUpCloseBar[0] && volume[0] >
volume[1] && LongTermTrendSlope < 0 && bycond1[1]);


# Plot with green arrow

# green triangle up at bottom of the bar C_RP Green arrow up 4 * tickSize for strong strength_In_DownTrend
plot isStrengthConfirmationBarPlot = if isStrengthConfirmationBar then (low - 5
* tickSize()) else if isStrengthConfirmationBar2 then (low - 9 * tickSize()) else Double.NAN;

# green triangle up at bottom of the bar C_RP Green arrow up 7 * tickSize for strongest strength_In_DownTrend with isUpCloseBar
# plot isStrengthConfirmationBarPlot2 = if isStrengthConfirmationBar2 then (low - 9 * tickSize()) else Double.NAN;

If you place this is the custom section by adding a study filter and opening up the thinkscript editor and poppong in the code. I also select a minimum stock price about 10 to filter out the low price stock.

Run the filter and wait for results. To verify that the filter worked OK open up one of the stocks and see verify that you have a green up arrow on the Daily chart. Of course you need to have the VSA study incorporated in the chart to verify this.

Happy trading.

Reply With Quote
  #375 (permalink)
kunevn
Ho Chi Minh HCMC/Vietnam
 
Posts: 5 since May 2012
Thanks Given: 3
Thanks Received: 1

Thank Hornblower for your reply! The label at the top-left corner , like this: "Test for supply", Up-thrust"...It's show for the current candle. I want to see the label for last closed candle. Thank you! (sorry my English, It's not my language )

Reply With Quote
  #376 (permalink)
Hornblower
Oxnard California
 
Posts: 10 since Aug 2012
Thanks Given: 2
Thanks Received: 23

The program provides indicators but does not flash alerts or a label in the upper left region except for current bar. I was also frustrated by this so I modified the VSA for looking at the labels at previous bars. When this program is installed change the input permeter "goback" by 1 you will be able to see the previous label. I liked to insert in as a lower study so it does not interfere with the VSA and I can compare the two. Be aware the values get shifted to the left by one for each increment of goback.

Now this code has not been modified to the latest VSA version so there are differences but when I was testing I liked to use it to check out the alerts and labels on a look back basis. Otherwise, you do not see previous alerts and label changes.

Attached Files
Elite Membership required to download: VSA_1DayBack.ts
Reply With Quote
Thanked by:
  #377 (permalink)
Hornblower
Oxnard California
 
Posts: 10 since Aug 2012
Thanks Given: 2
Thanks Received: 23

Within this thread was provided a Better Volume Indicator that considered by Volume and Price to a volume chart. Each of the volume bars on the histogram was color coded to reflect volume values in relation to price using the Volume Spread Analysis rules. Also used to support Wyckoff Tests of Accumulation.

Here is brief description of the Better Volume Indicator.

"The Better Volume indicator uses a combination of bid/ask volume and range to identify Volume Climax, High Volume Churn and Low Volume bars. Market tops are characterized by Volume Climax Up bars, High Volume Churn and Low Volume Up bars (also called Testing). Market bottoms are characterized by Volume Climax Down bars, High Volume Churn and Low Volume Down bars (Testing). Pullbacks, in either up or down trends, are similar to market topping or bottoming patterns, but shorter in duration and with simpler volume patterns. The Better Volume indicator works in all markets and for all time frames but is particularly useful for tick charts."

To better read the histogram bars I have added labels to describe the latest volume bar. Other than that, the Better Volume Indicator is not changed. This indicator works well with the latest VSA.

Let me know if any changes are needed to improve it further.

Hornblower

Attached Files
Elite Membership required to download: BetterVolume_Indicator_WLabels_Study.ts
Reply With Quote
Thanked by:
  #378 (permalink)
kunevn
Ho Chi Minh HCMC/Vietnam
 
Posts: 5 since May 2012
Thanks Given: 3
Thanks Received: 1

Hello Hornblower!

Do you check all the label and symbol in program VPAv1_08.ts with TOS_Ninja_VPA_CHEAT_v01.xls? I feel something incorrect symbol position and color.

Ex: the label "Less Bearish on Failed UpThrust Confirmation". It's show the green rectangle at the upper bar.

I think the label is right but the symbol wrong position and color.


Reply With Quote
Thanked by:
  #379 (permalink)
kunevn
Ho Chi Minh HCMC/Vietnam
 
Posts: 5 since May 2012
Thanks Given: 3
Thanks Received: 1

Sorry I cannot post link and image!

Reply With Quote
  #380 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,460 since Jun 2009
Thanks Given: 33,234
Thanks Received: 101,655



kunevn View Post
Sorry I cannot post link and image!

You can attach images, but cannot link to them from external sites.

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
Thanked by:




Last Updated on May 21, 2023


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
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.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts