Question

preparing data from a DDE link for charting

Asked by: steve0412

Can anybody help me with the appropriate VBA code to handle the following problem:

I have a DDE link which generates data from another app into Excel. I need to chart this data by taking a sample every n seconds, and then over a period of x seconds, extract the start value, the end value, the maximum and the minimum value to create a chart that is updated in real time for an unlimited number of n minute samples.

Help is appreciated (Excel 2000 SP3)

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2005-11-10 at 11:46:44ID21626835
Tags

dde

,

excel

Topic

Microsoft Excel Spreadsheet Software

Participating Experts
1
Points
450
Comments
51

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Using Excel's DDE function--urgent!
    I need to use the DDE functions of excel in VB5. (i.e. DDEIntiat). The serve is not excel, but is setup like excel. I am writing a VB5 program to do DDE with it.
  2. DDE between Excel and Visual Basic
    I want to connect a Visual Basic picture box with a Excel graphic via DDE. But I don't know which item's name is a graphic in Excel for the linkitem propertie. For example, if I'll want to connect Visual Basic with a Excel cell, i'll push RxCx like linkitem, where x is the ce...
  3. DDE
    Context: VB6/WinNT/DDE I need to write a DDE aware application in VB. I'm lost in matters of DDE and need some guidance. My app need to act as both client and server. Furthermore if the app is not running and someone tries to establish a DDE connection the app should be laun...
  4. DDE - Close Word
    I need to close MS Word through a DDE channel... What is the DDE comand for doing this?
  5. DDE
    am new to dde. I want to have vb6 communicate with another application. The other application is a window based program wich has dde capablities. It's called WTK (informix danymic 4gl program) It's used to communicated to unix box. Anyway my problem is that i don't know how ...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: bruintjePosted on 2005-11-11 at 01:10:14ID: 15272218

Hello Steve0412,

The people from QuoteIn used a very smart non VBA method to achieve this

source: http://www.quotein.com/qlcgi/wiki.pl/Examples

Check the charts sample workbook, it uses some workbook formulas to update the chart based on a running feed. It's not DDE but RTD which would be the best solution except if you're not in charge of the tool providing your realtime feed. However Reuters has a RTD plugin and maybe Bloomberg has one too. Today most vendors can deliver a plugin to do RTD instead of DDE but that's just a thought not sure of course how yoiur setup is.

Hope this helps a bit
bruintje

 

by: steve0412Posted on 2005-11-11 at 09:41:58ID: 15275306

Can you explain the technicalities of RTD. Is it an alternative standard to DDE?

 

by: bruintjePosted on 2005-11-11 at 09:54:20ID: 15275402

maybe i was not completely clear, you can use DDE with the chart sample above because the changes to the series are made with looking at the time field that's coming in with the quote not the event of a changing quote/cell. i assume that you have such a field [tradetime or something] in your DDE feed too

now that's hopefully clear on to RTD

RTD is indeed an alternative standard for realtime data feeds into Excel and i heard very recently from someone with Microsoft Excel that they're going to fully support this standard into version 12 and up of Excel.

In simple words you create a server component that's serving the feed, and in Excel you add cell formulas to ask your data from the server, the great thing is Excel will stay totally responsive so any update is being fed through linked cells etc.. no need to catch events and all difficulties you had trying to make DDE work seemless. So the bulk of the work is in creating a server component that's being fed with the data and translating that to fields that Excel can use, but once done it will pay off in easy of work on the frontend (Excel).

i'll enclose some links of samples (there are not a whole lot out there)

title: Real-Time Data: Frequently Asked Questions
source: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnexcl2k2/html/odc_xlrtdfaq.asp

title: How To Create a RealTimeData Server for Excel 2002
source: http://support.microsoft.com/kb/285339/EN-US/

title: HOW TO: Set Up and Use the RTD Function in Excel 2002
source: http://support.microsoft.com/?kbid=289150

hope this helps a bit
bruintje

 

by: bruintjePosted on 2005-11-11 at 09:56:46ID: 15275427

but now i'm reading you're using Excel 2000, no RTD available there so i probably made only the point of an incentive to upgrade once Excel 12 is there next year ;-)

as said the charts sample provides some nice workaround that could be of use in your situation and frees you from having to write code

 

by: steve0412Posted on 2005-11-11 at 10:19:59ID: 15275637

I have looked at the quite in stuff, but I cannot see how it works!

If I had the VBA experience I would write it but I can't (yet)

The func spec is:

Put the DDE link in A1. At n interval seconds, copy and paste the value to the next available empty cell (assume A2). After x seconds, take the series, and calculate the open (a2) the close (a2+x/n seconds) and the max and minimum values. Paste these values in cells C1,D1,E1,F1. Clear the range and begin again. On the next cycle, the values are pasted to C2,D2,E2,F2. The file is saved after each pass.

Is this difficult?

regards

Steve

 

by: bruintjePosted on 2005-11-11 at 10:27:09ID: 15275700

Steve, that shouldn't be to difficult, i'll hack something together with comments to see what happens and will post in an hour or 2 or sooner depending on how much time "worldy things" claim :-)
Brian

 

by: bruintjePosted on 2005-11-11 at 12:24:29ID: 15276646

this is a sample of a way to do what according to the spec
it contains one module with this code, a bit large because i had to fake a feed
it all starts with the sub StartAll() which fires of 3 timers, 1 for the feed, one for the quote shift and one for the creation of a ohlc record that gets copied to a second sheet where a timestamp is added

source: www.traktiq.net/ee_temp/ee-xl21626835.xls

-----------------
Option Explicit

Public m_lngSeriesRow As Long
Public RunWhen As Double
Public Const cRunIntervalSeconds = 15         '15 seconds minute
Public Const cRunIntervalSeconds2 = 60        '60 seconds
Public Const cRunIntervalSeconds3 = 5         ' 5 seconds
Public Const cRunWhat = "CreateQuote"         'this copies the quote
Public Const cRunWhat2 = "CreateQuoteRecord"  'this creates a ohlc quote
Public Const cRunWhat3 = "RunFeed"          'this starts the feed

'for more info on the scheduling in excel check
'source: http://www.cpearson.com/excel/ontime.htm

Sub StartTimer()

RunWhen = Now + TimeSerial(0, 0, cRunIntervalSeconds)
Application.OnTime earliesttime:=RunWhen, procedure:=cRunWhat, _
     schedule:=True
End Sub

Sub StartTimer2()

RunWhen = Now + TimeSerial(0, 0, cRunIntervalSeconds2)
Application.OnTime earliesttime:=RunWhen, procedure:=cRunWhat2, _
     schedule:=True
End Sub

Public Sub StartFeed()

  RunWhen = Now + TimeSerial(0, 0, cRunIntervalSeconds3)
  Application.OnTime earliesttime:=RunWhen, procedure:=cRunWhat3, _
     schedule:=True
 
End Sub

Sub StopTimer()
   On Error Resume Next
   Application.OnTime earliesttime:=0, _
       procedure:=cRunWhat, schedule:=False
End Sub

Sub StopTimer2()
   On Error Resume Next
   Application.OnTime earliesttime:=0, _
       procedure:=cRunWhat2, schedule:=False
End Sub

Sub StopFeed()
   On Error Resume Next
   Application.OnTime earliesttime:=0, _
       procedure:=cRunWhat3, schedule:=False
End Sub

Public Sub StartAll()
  '//set variables
  Worksheets("Data").Cells(2, 2) = 2
  m_lngSeriesRow = 1
 
  '// timers at work
  StartFeed           'for this sample we start the timers here
  StartTimer          'for this sample we start the timers here
  StartTimer2         'for this sample we start the timers here
End Sub

Public Sub StopAll()
  StopFeed           'for this sample we start the timers here
  StopTimer          'for this sample we start the timers here
  StopTimer2         'for this sample we start the timers here
End Sub

' run a random generator to change
' cell value as pseudo feed in cell A2

Public Sub RunFeed()
Dim N As Long

  Rnd -1
  Randomize 500 * Worksheets("Data").Cells(2, 1).Value
 
  Worksheets("Data").Cells(2, 1).Value = Rnd
  StartFeed ' restart the feed
End Sub

'get cell value, insert a row below and paste value
Private Sub CreateQuote()
 
  Worksheets("Data").Rows(3).Insert xlShiftDown  'insert a new row
  Worksheets("Data").Cells(2, 2) = Worksheets("Data").Cells(2, 2) + 1
  Worksheets("Data").Cells(3, 1) = Cells(2, 1)   'set value equal to quote
  StartTimer 'we need to restart the timer

End Sub

'create calculate open, high, low, close record
Private Sub CreateQuoteRecord()
 
   m_lngSeriesRow = m_lngSeriesRow + 1          'add 1 to our row counter for the chart data
   Worksheets("Data").Range("quoteRecord").Copy 'we copy our ohlc record to the chart sheet
   Worksheets("ChartData").Range("A" & m_lngSeriesRow) = Now() 'add a time
   Worksheets("ChartData").Range("B" & m_lngSeriesRow).PasteSpecial Paste:=xlPasteValues 'paste the record
   ThisWorkbook.Save
   Worksheets("Data").Cells(2, 2) = 3 ' reset counter for this record
   StartTimer2 'we need to restart the timer
   
End Sub
-----------------

hope this helps a bit
bruintje

 

by: steve0412Posted on 2005-11-11 at 14:46:12ID: 15277447

Hi Brian

I appreciate your hard work, but it is getting late here in Europe. I will implement tomorow and report

Steve

 

by: bruintjePosted on 2005-11-11 at 14:49:20ID: 15277459

that's ok Steve, we're on the same side of the ocean it's almost 0000 here in Amsterdam :)

 

by: steve0412Posted on 2005-11-13 at 06:39:07ID: 15283331

Hi Brian

I have tried it using my own DDE link but it has thrown up some spurious data (that I think is to do with your random feed!) I only kicked off StartTimer and StartTimer2. Is there a way I can show you the result?

 

by: steve0412Posted on 2005-11-13 at 07:09:21ID: 15283423

The other thing is thatit does not want to close. Even if I stop all the macros, it immediately re-opens

 

by: bruintjePosted on 2005-11-13 at 07:18:15ID: 15283450

what's probably easiest with using your own links is commenting out the startfeed and stopfeed entries in the code. that way they are not started at all and the timers will only try to log the data that's coming in through the DDE link in the cell A2

EE is a bit limited on communications except for the threads here

mail is in my profile

 

by: bruintjePosted on 2005-11-13 at 07:20:03ID: 15283458

reopening will occur if the timers are still running, will look into that and be back a bit later

 

by: steve0412Posted on 2005-11-13 at 07:41:40ID: 15283513

The 'spurious data' is the current time. I have no idea why this is being created

 

by: steve0412Posted on 2005-11-13 at 08:25:22ID: 15283632

It seems that for some reason, the current time instead of the DDE feed (I have replaced your random feed with the actual DDE link) is being entered.

It is probably easier to see what is going on with the actual DDE data coming in.

If you have the inclination, you can download the application (after registering)

http://www.forextradermentor.com/tmsignup.html

and run it in evaluation mode. You can then see the  View>DDE data out links to get the link. I am using TraderMetrics|DataOut!RawBid as the feed.

The other thing that I noticed is that their seems to be some relative cell references here. Can I replace them with named references and can I hide these sheets, so that the eventual chart page is the only one visible?

regards

Steve






 

by: bruintjePosted on 2005-11-13 at 10:38:01ID: 15283993

wow, i fixed the timer problem which was a bug from my hand and changed the cell reference for the open field which was wrong the workbook download is updated www.traktiq.net/ee_temp/ee-xl21626835.xls

will now try to get the same setup as yours to see what's happening

 

by: steve0412Posted on 2005-11-13 at 11:02:59ID: 15284053

Hi Brian

Definitely working better although 0 for initial open rate will screw the chart (IMHO). Still getting time instead of DDE link if I have focus on the chart sheet .

 

by: bruintjePosted on 2005-11-13 at 12:28:53ID: 15284332

Hi Steve,

Seems to be working ok with the DDE link, but i can't find an entry for the time in the DDE links.

I've changed it so both data sheets are not visible after you start the app.
The chart is updating only the last 15 ticks from the chartdata sheet.
It still using the time of timer not the time you could get from the DDE link.
To stop you need to use tools > macro > macros > choose stopall > run

you can download a new version www.traktiq.net/ee_temp/ee-xl21626835.xls

just comment on how it works out

Brian

 

by: steve0412Posted on 2005-11-14 at 13:30:49ID: 15291211

Hi Brian

I have run it from the TraderMetrics data and it is fine, apart from the fact that I cannot reset the data (that is, the data from you session is there at completely different rates.

I am confused to as to where the data sheet 'disappeared' to after I viewed the chart sheet. So, How do I stop it again?

Now you have got this far, perhaps for a couple of hundred points, you would provide the following functionality?

1)  Replicate the data in Excel  H-L-C format (which requires a different order for the columns), line data (based on closeing price)  or even make a toggle between the three..

2) The source data is sometimes 'compressed'. That is 1 minute 'realtime' represents n minuyes (up to a couple of days) in simulated data. So the graph x scale would show the compressed time, say each 'period' being 15 minutes in stead of 1 minute

3) The time scale for the OHLC/HLC is configurable (i.e. a OHLC at anything from 15 seconds to 1 day)

4)I work with Fibonacci retracements and extensions. This invoves setting 6 values and displaying as horisontal lines on the Y access.

5)The possibility to pre-populate the chart with data, so the 'live' session is showing a continuation of the data (i.e that being produced through the DDE link).

As you can see I have set 200 points to the total but let me know if you think it is worth more :-). Fabulous job so far which will help my students greatly.

regards

Steve

 



 

by: bruintjePosted on 2005-11-14 at 13:47:56ID: 15291337

Hello Steve,

i'll work on this tomorrow and post a new workbook around the end of the day

Add the start and stop on the toolbar.
A cleanup routine for previous runs so every run will start with fresh data.

1. a toggle button for three kind of charts based on the same data will be added
2. ok, at this point each period is read from the input and it's not configured to be time or date just what happens to be the input have to see how this plays out
3. i think this is already possible as a feature of excel itself where it compresses the data itself
4. this one i like myself ;)
5. this will be another button on the toolbar that you can run the dde feed until it has enogh data to fill the chart and it stops untill its started again with the start button

Looks like work, but these kind of sheets are a personal favorite so the points are ok :)

Brian

 

by: steve0412Posted on 2005-11-14 at 14:07:59ID: 15291512

Regarding setting the sample periods (so that nothing is misunderstood)

The period of the OHLC sample can be as low as 15 seconds (extreme frequency) up to daily OHLC and anywhere in between (normally 5 minute, 15 minute, hourly).

To simulate several days (or weeks/months/years), it is unrealsitic to have someone run a simulation for that length of time (as well as getting RTE 6 overflow errors!). So what I do is create a compressed time file, so that say, 1 hour is represented by 1 minute of real time data. I would like the time on the x graph to reflect this, but I admit that because TraderMetrics does not generate a DDE timestamp (unfortunately left out of the spec!), it would have to be set manually within the spreadsheet, overriding the 'normal' sampling time, or at least working in combination.

 

by: bruintjePosted on 2005-11-15 at 16:32:51ID: 15300383

Hello Steve,

Just have uploaded what i'll have thus far.

There is setup page to start with
It contains a start and stop button (both done)
You'll find there a button to fill in the fibo levels, and type of chart (1 and 4)
The chart starts building with enough data (15 ticks in this case)

todo
The adding of the Fibo lines is not working yet
I will look at the timeframe setup tomorrow

I'll finish the todo and that's it for this question.

Follow up can be done in new questions, it's not about the points but more to keep the balance between work and a question on EE ;-) And at the end i'll post all code here so anyone can help in a follow up question.

Regards
Brian

 

by: steve0412Posted on 2005-11-16 at 03:07:19ID: 15302278

I'm extremely impressed

 

by: bruintjePosted on 2005-11-16 at 06:58:05ID: 15303554

Hi Steve,

A new version is uploaded.

You can prepopulate a chart with the first 15 ticks (minutes in this case)
Then you can use Startquotes to start the timers and the normal run
I add fibo levels automatically, but i guess you want them different or as a choice yes/no
The fibo levels are taken from the difference of the current move  --> (high-low)*fibo and added to the low. The high and low are for the current 15 tick period only.

I think the only thing that is not yet implemented is the timing ranges.

Let me know what you think

Best regards
Brian

btw. I've played a bit with the simulator while waiting for the data and its fun :-)

 

by: steve0412Posted on 2005-11-16 at 10:49:24ID: 15305591

Hi Brian

I am not sure where I am prepopulating the chart data from, but in any case I got a message saying that Excel could not create the HLC chart. (I am giving you the errors as they occur so as to speed upm development! Unless you want me to close it here and start a new question)

 

by: bruintjePosted on 2005-11-16 at 11:10:54ID: 15305763

Hi Steve

it's ok you can post here, till we got this one working
for the prepopulation i assumed the simulator application DDElink to be up
the only difference with a normal run is that it stops after it creates the chart based on 15 minutes

i've ran it on the DDE simulator for OHLC and the Line chart of course i forgot the HLC will check now

Brian

 

by: steve0412Posted on 2005-11-16 at 11:21:32ID: 15305863

It is up. How can I get the resulting sheet back to you so you can review it?

I have tried to reset the sheet, but the values are still present.

If you like, I can register you (you go to the Help>registration information in TraderMetrics and give me the PIC code, and send you the same file that I am working on (i.e. a longer period)

 

by: steve0412Posted on 2005-11-16 at 11:22:42ID: 15305876

forget the last comment on the clean up - when I reverted back to the sheet, the sheet had cleaned itself up!

 

by: bruintjePosted on 2005-11-16 at 11:33:48ID: 15305960

cleanup is called on closing and reopening the sheet, i will change that to the setup button

 

by: steve0412Posted on 2005-11-16 at 11:36:45ID: 15305990

Another thing re: Fibs

You have (amazingly!) set the values to the right levels. (How did you know this?)

I had the idea that I could put in the equivalent rates "on the fly". for example 0%=1.2095 61.8%=1.2116, 38.2%=1.2129,100%=1,2150 123.6%=1.2163 161.8%=1.2184,223.6%=1.2218
putting in those absolute rates and then plotting a horizontal line for the value across the y axis. When one fib signal passed, the numbers could be reset when the next howed up.

If I could, I would like to show you what that looks like on a pro charting application!

(When I opened the workbook to do the calculation there, I got a RTE 9 subscript out of range - I suspect because the wrong book was activated. That is not so favourable as my students will have to work with at least one other workbook))


 

by: bruintjePosted on 2005-11-16 at 11:50:36ID: 15306109

currently i'm doing the CMT course trying to broaden my horizon and positioning myself to become a technical analyst in some time and that's were the fib levels come from :-)

the error i'll look into didn't test it that  way, and thats exactly what a test is for ;)

 

by: steve0412Posted on 2005-11-16 at 12:01:22ID: 15306182

This is the data in the raw data sheet


feed            open      high      low      close      fibo1      fibo2      fibo3      fibo4      fibo5      fibo6
1.2222      2                              0      0      0      0      0      0
1.2222                                                                  
1.2222                                                                  
1.2222                                                                  
1.2217                                                                  
1.2221                                                                  
1.2229                                                                  
1.2235                                                                  
1.2244                                                                  


and this is the chart data

                              fibo1      fibo2      fibo3      fibo4      fibo5      fibo6
16/11/2005 20:58                              0      0      0      0      0      0
16/11/2005 20:58                              0      0      0      0      0      0
16/11/2005 20:57                              0      0      0      0      0      0
16/11/2005 20:57                              0      0      0      0      0      0
16/11/2005 20:56                              0      0      0      0      0      0

The fibs are set to:

1      1.2095
2      1.2188
3      1.215
4      1.2115
5      1.223
6      1.2245
      1

I must have set it up incorrectly, but this is what I see, and obviously no chart data. I guess I am missing something here.

I hope that this information helps more than it doesn't !

 

by: bruintjePosted on 2005-11-16 at 12:18:20ID: 15306326

there is a new version posted that handles your latest post and the cleanup, i posted a wrong version in the afternoon which emptied out the formulas in the rawdata sheet

 

by: steve0412Posted on 2005-11-16 at 13:31:51ID: 15306966

By the way, an example of the fibonacci chart as I would like to present the data (the diagonal line is not so important and I guess difficult to replicate) is here

www.forextradermentor.com/eetemp/fibsample.jpg



 

by: bruintjePosted on 2005-11-16 at 13:50:12ID: 15307129

Hi Steve,

saw that there was indeed a problem with using this workbook in conjunction with another. thought that the thisworkbook reference was used everywhere but it wasn't. now this bug shouldn't be popping up anymore and the strange markers on the fibo levels are gone too in the latest upload (1038PM)

can you explain a bit more how you want the fibo levels being calculated?

at this point i calculate them by taking the difference between the high and low of the period and add them to the low, but i guess you have another idea looking at your latest chart?

i think the little bugs that you mentioned earlier are now gone,

i can add a counter to show the progress of the prepopulation because that takes a bit of time
next add a box on the config screen to change the periods between the ticks
and change a bit on the calculation of the fibo levels

but that should be it for this thread :-)

as said i'll post code and instruction at the end of this thread for others to reconstruct since this is EE and i can't guarantee to be available at all times besides there are some good excel gurus in this TA  to help you if needed

this is my last post for the day, so see you tomorrow

Brian

 

by: steve0412Posted on 2005-11-16 at 14:10:05ID: 15307291

Hi

I got it working. I see you have actually done the calculations on the fib levels. I have a spreadsheet based calculator that does this, so despite your excellent efforts, what is required is just the input for 7 (not 6 - my mistake) fibonacci levels based on the user's calculation, so that he can see the entry and exit targets.

(The aim of the exercise is to train traders to enter, set stops and limit orders, using a file with several opportunities to plot trading signals in one session)

Therefore, the levels need to be adjusted 'on the fly', and color differentiated for ease of tracking.

Using the target % as you have done requires that the direction of the trend is known and the first and second (0% and 100%) are entered, although it would be self explanatory which direction is required if the 0% was higher or lower than the 100%.

For this exercise, I use the 0% and 100%, the 38.3% and 61.8% as retracements and the -23.6%, -61.8% and the -1.236% as the extensions.

Hope that makes it clearer, but thanks for the time dedicated to this.

Steve

 

by: steve0412Posted on 2005-11-16 at 14:20:58ID: 15307363

Just to answer the other question. I cannot comment on the pre-population as I don't know exactly the philosphy, unless it is possible to run the simulation for n minutes to get the data, stop and save the workbook and then start running it with additional appended data at a later stage, This would be so that there was some chart history.

If that is so, I need to define the length of time of prepopulating, as well, of course, being able to adjust the sample time to creat variable period OHLC.

Steve

 

by: bruintjePosted on 2005-11-17 at 14:27:48ID: 15315958

Hello Steve,

A new version is posted.

The setup for has 7 entries for fibo levels
It also has an entry for the number of prepopulation OHLC records needed to chart at first
And it has one box for the time between 2 ticks
And it has one box for the time needed to form a OHLC record

The fibo levels are drawn in a continous line of various colors

Hopefully this works better

Brian

 

by: steve0412Posted on 2005-11-18 at 08:09:22ID: 15320625

Hi

Wll, it is working, but I got a run time error

(www.forextradermentor.com/eetemp/error1.jpg) which debugged to here:
(www.forextradermentor.com/eetemp/error2.jpg)

Perhaps because I was running in the browser?

Anyway, there are some puzzling things happening.

1) The fib series: I cannot see that this is so difficult to enter directly from the worksheet and why they have to be on a separate axis?
If I want to draw a horisontal line, I just create a column with the same values copied down to draw them as a series. This would be far simpler as I only need them as a visual reference and so they can be changed at any time

2) Why do I only see the last 6 entries on the graph?

(www.forextradermentor.com/eetemp/chart1.jpg

3)What about the graph scaling? It is showing the same tendencies that I put in a previous question (i.e Showing min:-1 and max:+1)  

4) Can you explain please how exactly to use the prepopulation?

Otherwise it is a great peice of work. If you can please have a look at the above, I will gladly sign this question off.

Steve







 

by: bruintjePosted on 2005-11-18 at 09:36:46ID: 15321473

Hi Steve,

After the domestic duties i'll be looking into those points and write a small how-it-works

The entering of the fibo series is indeed not so difficult to do by hand, what i'll probably do is put them in a seperate sheet where they can be changed while the chart is being made. IT's more of a leftover of the first prototype which calculated the series on the fly.

Brian

 

by: bruintjePosted on 2005-11-18 at 16:33:12ID: 15324113

Hello Steve,

the setup sheet (ready for download) contains now 3 small lists

- fibo levels
- chartttype
- timer settings

1. the fibo are now set as a constant series in their own sheet
2. you see as much bars as you prepopulate
3. not sure what you mean by this, the fibos are on their own axis because their charttype is line and the other is bar or ohlc those 2 bite each other on one axis
4. you start a sheet, then set the three config lists.

> 7 fibo levels

> set a 1 after the charttype you want to use other 2 should be blank

> the timer settings
prepopulate lenght (= number of bars to plot to start)
tick (= length of one tick in seconds)
quote bar (=lenght of bar before the next bar is calculated in seconds)

Next you use the prepopulate button to add the number of bars to start with/from
In the statusbar you see an indication of how far the progress of prepopulating is
Aftre the messagebox that its done
You can change the field for the prepopulation to set it longer or shorter
Then you click start timer and this will run the chart
Youcan use the stop timer button anytime to stop the application

Hope this is clear, sometimes i can write it easier in code then a simple helpfile

again could you explain what you mean by -1 and 1 for the axis? are you changing something manual or is that needed?

The new sheet is a bit larger then the previous one, this comes from the prepopulation i've done for the fibo levels to contain already 1000 rows. The application will only use as much as is displayed not all 1000 so you can easily delete some rows.

off for now

Brian

 

by: bruintjePosted on 2005-11-18 at 16:35:34ID: 15324127

PS there was a bug in the prepopulation that would erase the prepopulation when you chose to start the normal run. Just to let you that there was something wrong indeed :)

 

by: steve0412Posted on 2005-11-19 at 08:33:11ID: 15326130

I have run the latest version and still seem to have a chart scaling problem. Please see the screen shot

www.forextradermentor.com/eetemp/scaling.jpg

 

by: bruintjePosted on 2005-11-19 at 11:21:44ID: 15326685

Hello Steve,

What i did was

- download the file to disk
- started the tradermetrics app
- started the preload on the excel sheet
- after 10 bars it gave me the message it was ready
- then i started the start quotes
- and still the chart did look ok with me

Could you describe how you got into this bug?

Brian

 

by: steve0412Posted on 2005-11-19 at 11:41:38ID: 15326727

I will do exactly what you did and let you know (although I am sure I did exactly that!)

 

by: bruintjePosted on 2005-11-19 at 11:49:53ID: 15326756

did you fill in the fibonacci retrace levels?  i think that is what you see empty levels, i'll fix that first

 

by: bruintjePosted on 2005-11-19 at 11:57:29ID: 15326785

a new version is uploaded, you can set a field if you want to use the fibo levels yes or no

 

by: bruintjePosted on 2005-11-19 at 11:58:21ID: 15326794

btw i use 1 or an empty field for the choice fields like the charttype and the use fibo levels

 

by: steve0412Posted on 2005-11-19 at 14:50:47ID: 15327400

So far, so good, but I am not running on Fibonacci numbers-further testing being done!

OK, I have used the settings as shown with Fibs and the graph screenshot shows the result with the unadjusted scale.

www.forextradermentor.com/eetemp/exhibitA.jpg

www.forextradermentor.com/eetemp/exhibitB.jpg

As you can see, the fib scale is 'off'

 

by: bruintjePosted on 2005-11-20 at 03:03:34ID: 15328710

a new version is posted

- you can set the inclusion of fibo levels by setting the yes = 1 or yes = emtpy
- the min/max are taken from the quote bars also for the fibo level axis
- there are gridlines added
- the format of the date is changed to hour:minutes

if this works as is then i'm willing to pick any other changes to the current setup but only in a new question on EE, it became more of a RAC like project instead of a standalone EE question :-)

 

by: bruintjePosted on 2005-11-20 at 12:12:36ID: 15330257

thanks for the grade

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...