Announcement

Collapse
No announcement yet.

For Ts Support Re: Likhovidov

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • For Ts Support Re: Likhovidov

    Andy

    Thanks for the prompt post of pag 18 S&C V. Likhovidov ICS.

    Unfortunately both of the two .efs gives the following error output:
    line 21:type Errror: Array has no properties.

    They are both in a new sub folder in main Formulas folder as inidcated by your instructions.

    Am I missing something ?

    Cordially

    Fabrizio
    Fabrizio L. Jorio Fili

  • #2
    Fabrizio,

    Could you please try the following formula for ICS. Let me know how it works.

    Thank you,
    Andy

    Code:
    /*************************************************
    Description	: This Indicator plots the Index of Chart Sentiment
    Provided By	: TS Support, LLC for eSignal
    *************************************************/
    
    function preMain(){
    	setStudyTitle("Index of Chart Sentiment");
    	setCursorLabelName("ICS",0);
    	setDefaultBarFgColor(Color.blue,0);
    	setComputeOnClose();
    }
    
    
    var EMA1_1 = 0;
    var EMA2_1 = 0;
    
    function main(BBlength,Deviations) {
    	if(BBlength == null)
    		BBlength = 55
    	if(Deviations == null)
    		Deviations = .5
    	
    	var i = 0, Body = 0, ThBot_Body = 0, ThTop_Body = 0, ThBot_Ushd = 0, ThTop_Ushd = 0,
    	    ThBot_Lshd = 0, ThTop_Lshd = 0, ColorCode = 0, BodyCode = 0, UshdCode = 0, LshdCode = 0,
    	    BBTop = 1, BBBot = -1, EMA1 = 0, EMA2 = 0;
    	
    	Body = Math.abs(open() - close());
    	UpperShadow = high() - Math.max(open(),close());
    	LowerShadow = Math.min(open(),close()) - low();
    	
    	BodyArray = new Array();
    	UpperShadowArray = new Array();
    	LowerShadowArray = new Array();
    	CandleCodeArray = new Array();
    	
    	for(i = 0; i < BBlength; i++){
    		BodyArray[i] = Math.abs(open(-i) - close(-i));
    		UpperShadowArray[i] = high(-i) - Math.max(open(-i),close(-i));
    		LowerShadowArray[i] = Math.min(open(-i),close(-i)) - low(-i);
    	}
    	
    	ThTop_Body = bb( BBlength, Deviations, BodyArray, BBTop);
    	ThBot_Body = bb( BBlength, Deviations, BodyArray, BBBot);
    	ThTop_Ushd = bb(BBlength, Deviations, UpperShadowArray, BBTop);
    	ThBot_Ushd = bb(BBlength, Deviations, UpperShadowArray, BBBot);
    	ThTop_Lshd = bb(BBlength, Deviations, LowerShadowArray, BBTop);
    	ThBot_Lshd = bb(BBlength, Deviations, LowerShadowArray, BBBot);
    	
    	if(close() >= open()){
    		ColorCode = 64;
    		if(open() == close())
    			BodyCode = 0;
           		else if(Body < ThBot_Body)
           			BodyCode = 16;
           		else if(Body < ThTop_Body)
           			BodyCode = 32;
       		else
                    	BodyCode = 48;
      	}
    	else{
    		ColorCode = 0;
    		if(Body < ThBot_Body)
                   		BodyCode = 32;
    		else if(Body < ThTop_Body)
                   		BodyCode = 16;
        		else
                  		BodyCode = 0;
    	}
    	if(UpperShadow == 0)
         		UshdCode = 0;
       	else if(UpperShadow < ThBot_Ushd)
            	UshdCode = 4;
       	else if(UpperShadow < ThTop_Ushd)
            	UshdCode = 8;
    	else
    		UshdCode = 12;
    
    	if(LowerShadow == 0)
          		LshdCode = 3;
          	else if(LowerShadow < ThBot_Lshd)
          		LshdCode = 2;
          	else if(LowerShadow < ThTop_Lshd)
          		LshdCode = 1;
    	else
    		LshdCode = 0;
    
    	CandleCode = ColorCode + BodyCode + UshdCode + LshdCode;
    
        	EMA1 = 2/25 * CandleCode + 23/25 * EMA1_1;
        	EMA2 = 2/25 * EMA1 + 23/25 * EMA2_1;
    	if (getBarState() == BARSTATE_NEWBAR){
        		EMA1_1 = EMA1;
        		EMA2_1 = EMA2;
        	}
        
    	return EMA2;
    }
    
    
    function bb(Length,StdDev,Array,Type) {
    	if(Length == null)
    		Length = 55;
    	if(StdDev == null)
    		StdDev = .5;
    		
    	var i;
    	var vSum = 0.0;
    	var vClose;
    	var BBTop;
    	var BBBot;
    	var SumSqr = 0;
    	var StdDev = 0;
    
    	for(i = 0; i < Length; i++)
            	vSum += Array[i];
    
    	if(Length != 0)
    		for(i = 0; i < Length; i++)
    			SumSqr += (Array[i] - vSum / Length) * (Array[i] - vSum / Length);
    	StdDev = Math.sqrt(SumSqr / Length);
    	BBTop = vSum / Length + StdDev * StdDev;
    	BBBot = vSum / Length - StdDev * StdDev;
    	if(Type == 1)
    		return BBTop;
    	else if(Type == -1)
    		return BBBot;
    }
    Attached Files

    Comment


    • #3
      Andy (and Fabrizio)
      Looks like it is running perfectly.
      Alex

      Comment


      • #4
        Andy, Alex

        Thanks.
        Actually now both the formulas ( the one posted time ago from page 18 of S&C) and the new one you posted works fine.

        Thanks again

        Fabrizio
        Fabrizio L. Jorio Fili

        Comment


        • #5
          Another Likdovidov's S&amp;C Article

          The September 2001 S&C describes another of Likdovidov's CandleCode trading solutions called "Light Up Your Trading System With CandleCode Trading". It privides a buy/sell alert scheme using doubly smoothed (MA21 and triplet) CandleCode bounded by Bollinger Bands. Can one of you learned professionals give me the EFS equivalent of the wealth-lab, technifilter plus and tradingsolutions examples of Likdovidov's code given in the back of that issue? Other might also find this valuable. It looks very good.

          Comment


          • #6
            I did a quick text search in the fileshare area using candlecode and came up with this CandleCode

            What came up on the search was the ics.efs file, which appears to be what you are asking for. The link I attached has this file plus some others. It does look like some of the other files on the link are directly related.

            Comment


            • #7
              LIIKOVIDOV

              Let me add a caveat:

              follow the TSSupport instructions: ICS AND BB-LIKHOVIDOV MUST BE IN THE SAME SUBFOLDER TO WORK

              Cordially
              Fabrizio L. Jorio Fili

              Comment


              • #8
                But the study we are referring to are not the ones that skippy is mentioning.
                AMOF they are from an article of S&C of July or august of thsi year at pag 18.

                So Skippy define if the date is right or post the exact date and page of the article you refferring .
                Fabrizio L. Jorio Fili

                Comment


                • #9
                  CandleCode Extension

                  The September 2001 S&C , page 20, is it. It describes another of Likdovidov's CandleCode trading solutions called "Light Up Your Trading System With CandleCode Trading". It provides an entry/exit system based on the CC function, a scheme using doubly smoothed (MA21 and MA3 triplet) CandleCode bounded by symmetrical Bollinger Bands. I'm not sure how much of what is needed is in your more recent ICS example of CC, or if they are just related. Examples are given in the above magazine for various coding platforms, leaving out eSignal of course. Can you provide me what is needed?

                  Comment


                  • #10
                    Skippy,

                    May help to ask Jason K. to attempt to code it, as I believe he is in charge of coding S&C stuff for eSignal. May want to ask him under EFS Library - Discussion Board >> Stocks and Commodities.
                    Michael

                    Comment


                    • #11
                      I cant get these 2 indicators to work!!!help

                      I cant get these 2 inidicators to work..what am i doing wrong..i just keep getting the error messages
                      FURIO

                      Comment


                      • #12
                        I have come across the efs development done for the Likhovidov ICS study. I downloaded what appears to be the most recent version of ICS.efs and bb_likhovidov.efs, and I am getting error messages in both. They are in the same subfolder.

                        ICS is calling an unknown formula. bb_L has an Array-related Type Error.

                        Has this work been updated in another thread?

                        Thanks very much.

                        Comment


                        • #13
                          jcprinster
                          If you are referring to the version posted in this thread make sure that the bb_likhovidov.efs is saved as bb.efs
                          If instead you are using the ics.efs posted in this same thread then that is a standalone version and does not require any external files.
                          Alex

                          Comment


                          • #14
                            Alex, yes, these are the scripts. I downloaded them again, to make sure I had the latest.

                            Here is the error message I am getting on the renamed bb.efs when I load it onto a chart:


                            ChartSentiment\bb.efs, line 21: TypeError: Array has no properties


                            ChartSentiment is a subfolder in my Formula folder.

                            The ICS.efs works fine.

                            Any ideas how to eliminate the error message and get bb.efs working?

                            Thanks you very much. Joe.

                            Comment


                            • #15
                              Joe
                              I just loaded them both and ran them without any problems (after renaming the bb_likhovidov.efs to bb.efs).
                              Regardless the ics.efs posted earlier in this thread returns the same exact results with the difference that it is self contained rather than split in two scripts
                              Alex

                              Comment

                              Working...
                              X