Announcement

Collapse
No announcement yet.

Moving Average from eSignal into Excel

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Moving Average from eSignal into Excel

    I have eSignal 7.4.

    I have used eSignal with sample spreadsheet to place symbol price data into excel in real time.

    How do I place an indicator such as Moving Average from eSignal
    into Excel. Preferably, I only need a single cell to keep the current value.

    Can you please be very specific in directions. I did a search for this in Forum, but was confused.

    I would like to just copy the Moving Average on a Chart in eSignal to Excel.

    Thanks much,

    [email protected]

  • #2
    Hi Seldin,

    You may want to read through the following thread regarding how to call moving average data through the DDE. Hope this helps.

    Comment


    • #3
      I read the URL, however, I am lost.


      In Excel, I can place a formula such as:

      =WINROS|LAST!SPY

      What is the formula for the SPY EMA(30)

      Otherwise, I looked at something called EFS. I saw in the library of my esignal EMACalc.efs. Do I call that somehow from Excel.

      I really just want the EMA(30) on the Daily chart that I already use. Can you walk me through this, on how to put this into Excel.

      Thanks much,

      [email protected]

      Comment


      • #4
        Hi,

        Try this out:

        Grab the DDE Excel EFS.efs file from this File Share group and save it under Program Files/eSignal/Formulas/Downloads

        Next, go into eSignal and open up the chart you use and choose the symbol and interval as you normally would.

        Now, right-click and choose Formulas, then Downloads. You should see the DDE Excel EFS file if you saved it with the same name. Click on that file and it'll load. You should then see DDE EMA30 in the upper left hand corner of the chart.

        Next, open Excel and go to a blank cell. Enter the following excel formula: =eSignal|EFS!EMA30GE5 ( but you'll replace GE with your symbol and 5 with the interval from your chart ) i.e. the symbol and the interval need to match what's actually in that chart with the DDE EMA30 loaded.

        You should see the correct value in Excel.

        Give it a shot. I hope these instructions are clear enough.

        Thx

        Comment


        • #5
          Scott,

          I appreciate you helping me out.

          As a reference. eSignal is located in c:\eSignal. I placed your file under c:\eSignal\forumulas\download.

          In eSignal, when I right click and choose formulas, downloads and choose DD file, I get error:

          A syntax error has occurred. Do you want to show formula output window.

          The file contains this message:
          Downloads\DDE sample EFS.ef line12:
          ReferenceError: DDEOutput is not defined.

          Can you please tell me what is wrong?

          PS. Can you tell me what I would change, to change EMA(30) to SMA(50)?

          Thanks much,

          [email protected]
          Last edited by seldin; 05-21-2004, 07:50 PM.

          Comment


          • #6
            Hi,

            I just duplicated my instructions from my home PC and it worked great. What version of eSignal are you running? If you are not running the latest (7.6 v3), please download the current version and try this again. The other choice is to open the EFS Editor and simply copy/paste the contents.

            On your second question, here's the contents of this EFS:

            var ddeEMA30 = null;

            function preMain() {
            setPriceStudy(true);
            setStudyTitle("DDE EMA30");
            setShowCursorLabel(false);
            }

            function main() {
            if (ddeEMA30 == null) {
            var sName = "EMA30" + getSymbol() + getInterval();
            ddeEMA30 = new DDEOutput(sName);
            }

            var vEMA30 = call("/library/ema.efs", 20);
            if(vEMA30 != null) ddeEMA30.set(vEMA30);

            return;


            You'd simply replace EMA30 with MA50 everywhere it occurs and save it.

            Thanks.

            Comment


            • #7
              Scott,

              I got it to work! Thank you much...

              Could I just ask one more question. How do I change the following code in Excel for a Daily Chart of $SPX

              =eSignal|EFS!EMA30IBM5



              Thanks much,

              [email protected]

              Comment


              • #8
                Good question!

                In a standard link, you'd use apostrophes for indices and futures.

                =winros|last!'$spx'

                but that's not functioning correctly in this EFS DDE link and despite my trying most of the logical syntax, I can't get one to work. I'll have to check with a programmer on Monday and let you know.

                For futures, the standard DDE link looks like this:

                =winros|last!'ES U4'

                The exception for Futures is already notated as needing an underscore for EFS DDE links and not apostrophes i.e. ES_U4

                Can't find any reference to indices so I'll check it out. If anyone else has figured this out, please chime in!

                Thanks.

                Comment


                • #9
                  >> =eSignal|EFS!EMA30IBM5 <<

                  Scott,

                  I actually have asked 2 questions.

                  1) How to create EMA(30) for symbol $SPX


                  2) How to reference a daily chart with correct syntax.


                  $SPX is key for me getting the EMA(30) into Excel.

                  I hope you can find the answer.

                  Thank much,

                  [email protected]

                  Comment


                  • #10
                    Hello Seldin,

                    The main issue with DDE links for excel has to do with spaces and special characters. They cannot be included in the name for the DDE string. In the code example below you'll see several lines where the .replace() method of the String object is used to remove the special characters $, #, and replace spaces with underscores. This code example also outputs the DDE string you need to enter in Excel to the formula output window. If you run this on a chart of $SPX,5 the DDE link would be:

                    =eSignal|EFS!EMA30SPX5

                    On a daily chart of ES #F, the link would be:

                    =eSignal|EFS!EMA30ES_FD

                    PHP Code:
                    var ddeEMA30 null;
                    var 
                    vMA = new MAStudy(300"Close"MAStudy.EXPONENTIAL);

                    function 
                    preMain() {
                        
                    setPriceStudy(true);
                        
                    setStudyTitle("DDE EMA30");
                        
                    setShowCursorLabel(false);
                    }

                    function 
                    main() {
                        if (
                    ddeEMA30 == null) {
                            var 
                    sName "EMA30" getSymbol() + getInterval();
                            
                    sName sName.replace("$"""); // remove $ from string
                            
                    sName sName.replace("#"""); // remove # from string
                            
                    sName sName.replace(" ""_"// replace space with underscore
                            
                    debugPrintln("DDE Link for Excel =eSignal|EFS!"+sName);
                            
                    ddeEMA30 = new DDEOutput(sName);
                        }

                        var 
                    vEMA30 vMA.getValue(MAStudy.MA);
                        if (
                    vEMA30 == null) return;
                        
                        
                    ddeEMA30.set(vEMA30);

                        return 
                    vEMA30;

                    To reference the Daily data of $SPX for excel, simply run the formula on a daily chart of $SPX. Your DDE link would be:

                    =eSignal|EFS!EMA30SPXD
                    Jason K.
                    Project Manager
                    eSignal - an Interactive Data company

                    EFS KnowledgeBase
                    JavaScript for EFS Video Series
                    EFS Beginner Tutorial Series
                    EFS Glossary
                    Custom EFS Development Policy

                    New User Orientation

                    Comment


                    • #11
                      I have eSignal 7.6

                      ERROR!!!!

                      I got error in Excel:

                      =eSignal|EFS!EMA30$SPX5

                      does not work

                      and

                      =eSignal|EFS!EMA30$SPXD

                      does not work either.

                      Can you please help me?

                      Can we please try to wrap this up quickly?

                      I have been hoping for a solution since last week.

                      Thanks much,

                      [email protected]
                      Last edited by seldin; 05-26-2004, 01:43 PM.

                      Comment


                      • #12
                        You're not entering the proper formula in Excel. Remove the $ from the string. It should be:

                        =eSignal|EFS!EMA30SPX5
                        Jason K.
                        Project Manager
                        eSignal - an Interactive Data company

                        EFS KnowledgeBase
                        JavaScript for EFS Video Series
                        EFS Beginner Tutorial Series
                        EFS Glossary
                        Custom EFS Development Policy

                        New User Orientation

                        Comment


                        • #13
                          >>You're not entering the proper formula in Excel. Remove the $ from the string. It should be:
                          =eSignal|EFS!EMA30SPX5
                          <<

                          That did not work. Also

                          =eSignal|EFS!EMA30SPXD

                          does not work.

                          Can you tell me what to do?

                          Can you actually try the code in ESignal and Excel, to see if it works for you. I use Excel 2000 and Esignal 7.6

                          Thanks much,

                          [email protected]

                          Comment


                          • #14
                            seldin
                            FWIW it is working here using 7.6 (636a) with the efs that Jason wrote and the suggested syntax
                            Alex

                            Comment


                            • #15
                              MOVING AVERAGES LOOK WRONG...

                              Thank you all for your valued input on this thread. I am trying to import MULTIPLE moving averages off of multiple charts. That said, right now when I plot a single moving average on the 30 EMA into a chart then pull the data into EXCEL using the .EFS as per Mr. Seldin, the #s differ from the chart to the EXCEL sheet (and yes, I am plotting the 30 EMA in chart as well as using the sample EMA30 .EFS file). Am I doing something wrong? Thanks a ton for your input as to why this happens....

                              Comment

                              Working...
                              X