 |
|
 |
Hi,
first of all, i want to thank you for this great and nice control.
So, i would like to know what license is attached to this control ? (In order to know what i can do with the code/the dll)
Thanks.
|
|
|
|
 |
|
 |
1. How to convert the calculated logarithmic values to array values?
2. How to display the logarithmic values when mouse moves?
Please help me because now i am doing a project like this.
Thnaks and Regards
Shibu Mathew
Shibu Mathew ; email:-shibumathew@sify.com,shibu.veerappallil@yahoo.co.in
|
|
|
|
 |
|
 |
I am a newbie in C# and I have a program which calculates the velocity of a ball at a particular time instant. I have stored the velocity in an array and same for time.
How can I integrate it to plot velocity vs time?
Regards,
Amit
|
|
|
|
 |
|
 |
" ...changed the program to diplay more than one data set in one diagram?
Please let me know as soon as possible...
THX "
If you know the solution could you please email me?
thanks
|
|
|
|
 |
|
 |
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'Dim pl As DataPlotter.Plotter
'pl = New DataPlotter.Plotter()
Plotter1.YLogBase = 0
Plotter1.YRangeStart = 0
Plotter1.YRangeEnd = 27
Plotter1.YGrid = 1
Plotter1.XLogBase = 0
Plotter1.XRangeStart = 0
Plotter1.XRangeEnd = 27
'Code here is where i need help. cant load anything into _
'plotter1.XData or plotter1.YData
Plotter1.XGrid = 1
Plotter1.Refresh()
End Sub
I guess what im basically trying to say is that im having troubles using the xdata and ydata properties from VB if possible.
having troubles getting points to appear on the graph. Is it because i am doing this in VB.net? Help asap thx yall!
by the way i just wanted to add in that im extremely novice with programmin in .net as you can all tell.
|
|
|
|
 |
|
 |
Good work, but i;Pf we set the logarithmic scale as 0.2 - 2000, the grid lines look like not correct.
|
|
|
|
 |
|
 |
That's is true. That's what I ment when I said in the article:
- For logarithmic scaling, use full decades for the RangeStart and RangeEnd properties, e.g. 0.01 to 1000 for a LogBase of 10.
There was a response of TRiegler below who can help you with this.
|
|
|
|
 |
|
 |
Can you add in your control one or more markers ?
I would like to use your control like a spectrum.
And a tracker for showing the value.
Best Regards
youssef
|
|
|
|
 |
|
 |
Great Work!
I wanna use it and extend it with some interaction functionality. Do you know an easy to decide if the mouse is over the curve when moving?
Thanks!
|
|
|
|
 |
|
 |
...changed the program to diplay more than one data set in one diagram?
Please let me know as soon as possible...
THX
|
|
|
|
 |
|
 |
Please I need this answer quickly.If you have already gotten a response, could you please email me ?
|
|
|
|
 |
|
 |
hello i have changed the code to display more than one plotter lines!
if you want to get the sample code contact me via email:
wolfgangd@gmx.net
best regards dawo
|
|
|
|
 |
|
 |
Greetings Hans-Jürgen,
This is a good sample.
Have you done something similar in VB6 with MSChart control? I do not have .NET available to me and have developed a project in which the output generated would be better served on a log-linear presentation.
I am having a tough time scaling the y-axis as logarithmic with:
RxChart.Plot.Axis(VtChAxisIdY).AxisScale.Type = VtChScaleTypeLogarithmic
RxChart.Plot.Axis(VtChAxisIdY).AxisScale.LogBase = 10
Any guidance would be greatly appreciated.
dg
|
|
|
|
 |
|
 |
Sorry, I never could get the MSChart control to display anything logarithmic, but I also didn't try it very hard...
Bye
Hans-Jürgen Schmidt
|
|
|
|
 |
|
 |
Not sure if you've ever tried to share code before, but your variable naming scheme in your OnPaint eventhandler are a lesson in how not to name variables. As for everything else looks great.
|
|
|
|
 |
|
 |
What is so special about his naming conventions, I wonder?
On this page many people use very strange naming conventions. So what?
I always have a lot of fun converting sample code from C# to VB.Net. People
are writing things like this:
public int PenWidth
{
get {return penWidth;}
set {penWidth = value;}
}
I will never understand why people use the same name for a property and the private variable. Really I will never understand! m_penWidth or something like this would be the proper name. Tending C# programmers to sloppiness?
Or do they just not think about languages which are case incensitive?
So, this is the standard 99% of C# programmers use here. I do not like it.
Nothing special about this code. And m_ or priv_ or something clearly marks variables as private opposed to local. This would help a lot, reading other peoples code. No wild guessing. Marking things with "this." ("me.") is also a nice way to make code readable.
|
|
|
|
 |
|
 |
Good work, it is just what i needed. Thank you for sharing your code.
ARK
|
|
|
|
 |
|
 |
I got nothing working. I can see only a dialog, no plot, no data in property Grid..
please help.. compilation is OK
|
|
|
|
 |
|
 |
I wanted to mention that I found your control very useful. There are some suggestions (other than what you've mentioned) which I can think of, and will be glad to share them with you if you like.
In particular, DataPlotter doesn't seem to deal with non integer decade spans (e.g. 25-50 or 4-1020), and I believe I can show you how to do this if you wish.
|
|
|
|
 |
|
 |
I ran the demo -- nice stuff. I noticed that resizing the window (and consequently the control) causes a lot of flickering as the control redraws itself. Without looking at the code, I may be mentioning something you've already tried, but in my experience this flickering is addressed very well by enabling double buffering within your control.
Try something like this in your constructor (from memory):
SetStyle(ControlStyles.DoubleBuffering, true);
There are other control styles that you may find optimise performance too.
Good stuff. Congratulations, and thanks for sharing your work.
|
|
|
|
 |
|
 |
Thanks a lot for your suggestion. Adding
SetStyle(ControlStyles.DoubleBuffer |
ControlStyles.UserPaint |
ControlStyles.AllPaintingInWmPaint,
true);
immediately after InitializeComponent makes it smooth and even faster
|
|
|
|
 |
|
 |
I too was originally frustrated by flicker, and added double-buffering to reduce this.
However, I was still frustrated by refresh rates. My solution is to do all drawing to an Image, and in OnPaint(), drawing the Image as opposed to drawing each individual line and box. So there are two cases within OnPaint(), the first time through we draw the control to the Image, store that Image within the DataPlotter class, and set a flag that the control has been drawn. Each subsequent call to OnPaint() simply re-draws that same Image.
Code changes include:
private Image myImage;
public int myStatus = 0;
protected oerride void OnPaint(PaintEventArgs e)
{
switch (myStatus)
{
case 0:
// image has not yet been drawn, or needs to be updated
Graphics g = this.CreateGraphics();
myImage = new Bitmap(e.ClipRectangle.Width, e.ClipRectangle.Height, g);
g = Graphics.FromImage(myImage);
..... your OnPaint() code inserted here, minus the Graphics g initialization you were using
// just before the end of the try block add this
e.Graphics.DrawImage(myImage, this.ClientRectangle);
myStatus = 1;
case 1:
e.Graphics.DrawImage(myImage, 0, 0);
break;
}
}
on Plotter_Resize(), add code to set myStatus to 0.
Anytime you update the data, set MyStatus to 0;
Performance gains using this method are quite significant. You will especially notice the difference if you drag another window over the control, with this method it runs pretty smooth.
Thanks!
|
|
|
|
 |
 | que  |  | Anonymous | 21:55 14 Oct '03 |
|
|
 |