Dynamic Line Graph
I am interested in adding a dynamic line graph to a form I have.
I attempted to use myChart with an array which pretty much went nowhere.
I have read a little on the subject which entails lots of script, which is ok, however I am lost and in need of some direction.
Can anyone point me in the right direction.
Creating dynamic graphs in a PDF is an very complex and a very advanced scripting task. If you need such graphs in your file, then PDF might not be the right choice for you.
Similar Messages
-
I want to have a line graph where the user inputs variables
in a text box and then the graph is generated by the click of a
button. Does anyone know how to do this or know where I could find
a tutorial on this?Check out the MovieClip class for the drawing API –
moveTo(), lineTo(), etc.
The rest will just be interface design and some maths.
For some reason I think that kglad has posted some code in
the forums for at least parts of such a thing. -
ADF Line Graph with dynamic series - can do ?
I want to implement a drill-down from a high level line graph into a lower level line graph. The master graph may have 4 series in it, and each of these 4 series may have 6 - 8 different sub-series that need to be shown in the lower level graph (so up to 30 in all sub-series). Rather than create 4 of the lower level graphs, what I'd like to be able to do is create the lower level graph once using a VO which reads the master graph context. The definition of a graph model however in the ADF at first glance doesn't appear to cater for this. Have others done this ?
Thinking that if I could:
a) define the detail VO so that it used generic columns for the series amounts
b) was able to override the series attribute name/label used for the legend etc. by way of code (backing bean?) for each series again based on context
c) was able to optionally hide a series that was not needed (as defined by the generic detail VO) for a given master context
... then maybe I'd have a chance. But b) and c) don't look catered for.
Anyone?
Using 11.1.For the record, I gave this a go, and was able to get it working satisfactorily. There was no way as far as I could tell to set the visibility of a series. So essentially, what I've been able to do is set the series label to blank, set the line width to 1 (min, doesn't seem to honor 0), and the color to white to match the background of the chart ... for those series that are superfluous in a given chart render. It works fine except for the fact that if you've used the highlight rollover series effect, if you move the mouse over the legend area where the "hiding" series are, you get a bit of flashing on the legend entries that are displayed.
Ideally, we'd have a way of actually taking these out entirely. If there's a way to do it, I'd be interested in hearing about it.
Thanks. -
First off, thanks to kglad for the line graph function I
started with, it has been a huge help. Now the step I'm trying to
take is 2 fold.
First, I'd like to graph more than one line segment on the
graph. Right now I am graphing functions f1 and f2, but f2
currently overwrites f1. I want them to coincide so f1 goes from
x=1 to x=15, f2 goes from x=15 to x=25, f3 goes from x=25 to x=10
at a different y (these are all curves), and finally f4 goes from
x=10 to x=1 creating a closed shape. Also, I want the x values and
the y values to be variable based on the temperature. I'm using
PV=nRT and n, R, and T are all known. so I have something like
P=nRT/V where P is y, V is X and the nRT can be calculated for two
steps of the 4. The other two steps are adiabatic, so Q=0, I don't
know yet how to fit the lines but i do know that y = a / (x^(5/3))
is a formula that works, I just need to find the proper a values
for steps 2 and 4.
Part two of this issue is that currently the graph is drawing
as the whole canvas, which is fine for testing until i get the
multiple line part worked out; however I only want this to be 1/4
of the viewing area as I have other movie clips and such to put on
this. A conceptual drawing of what I plan on making can be found
at:
http://www.students.bucknell.edu/gbement/Steps.html
I'm a novice to Actionscript and movie clips, I previously
did everything with motion tweens and nothing was dynamic. I plan
on creating the piston and molecule simulation in another movie
clip, then I can vary the play speed relative to the hot and cold
temperatures by looping the movieclip and having it play faster for
a high T and slower for a low T.
Any help on any of my many issues would be greatly
appreciated and the user will be recognized for their assistance in
my research presentation :)Hi Arun, thanks again for the help but upon closer inspection
(along with only a basic knowledge of java and actionscript), I
think your script would need editing to work for me (editing i'm
unsure of how to do). What I'm looking for is a graph that will
create a line based on a function. Much like y=(a*b*c)/x or
y=(a*b*c)/(x^1.66) The a*b*c would be complicated also, but here's
what i've thought up on paper that I have to move to script, I hope
this is useful:
Step 1: Calculate the a*b*c
The original function is PV=nRT , nRT being the a*b*c ,
however the Thot and Tcold terms are input boxes that the user
types in before hitting the "go" button.
So I have to do this much:
tcold = Number(tcold_num.text);
thot = Number(thot_num.text);
var n:Number = 1;
var R:Number = 0.0825;
var a:Number;
var b:Number;
var c:Number;
var d:Number;
a = n*R*thot // Step 1 constant
b = // Step 2 constant (formula to be finished :-/) Looks to
be a formula using ((b) / (Math.pow(x, 1.666)))
c = n*R*tcold // Step 3 constant
d = // Step 4 constant (formula to be finished :-/)
Then I need to find a way to initialize axis to line the
graph, I can label the P and V axis using static text boxes later I
suppose.
The problem I have with yours that I don't understand is that
I could add the function into the y part of the addLine() function,
however it's noted as inity= y1 (requires a number), and the
function definition has y1:Number.
Now the issue i'm tackling below is just a newbie's lack of
understanding (i hope), but the script kglad wrote (snipped below)
will graph one line, and i can't figure out for the life of me how
to write this up to graph more than one instance without
overwritting the previous line. Again, Thanks for the help so far,
it has helped me find the points where I lacked direction and solid
ideas before. -
Hi,
I have a query like this below which will return 25 rows when i run this in a SQL work shop when i execute this in Line graph it only shows data for 15 rows remaining 10 rows are missing please suggest me what would be the mistake
Here no dates are repeated. i see lines only for 15 rows remaining 10 are missing this is happening if the data is 15 rows the limit for line graph or some changes can be made.
SELECT
null,
TP.WEEK_ENDING_DATE "Week Ending Date",
SUM(TCL.NUM_HOURS_DAY1+TCL.NUM_HOURS_DAY2+TCL.NUM_HOURS_DAY3+TCL.NUM_HOURS_DAY4+TCL.NUM_HOURS_DAY5+TCL.NUM_HOURS_DAY6+TCL.NUM_HOURS_DAY7) "Total Actual"
FROM
timecard_lines tcl,
project_objects pobj,
tasks tas,
projects pro,
timecard_headers thr,
employees epl,
TIMECARD_PERIODS TP
WHERE
PRO.ID = :P67_PROJECTS AND
TP.ID = THR.TPD_ID AND
tcl.pobj_id = pobj.id AND
tcl.tas_id = tas.id AND
pro.id = pobj.pro_id AND
thr.id = tcl.thr_id AND
thr.emp_id = epl.id AND
pobj.id = tcl.pobj_id
AND
pro.id in
(SELECT pro.id
FROM projects pro, employee_project_pairs
epp, project_employee_roles per ,employees empl
WHERE empl.id = epp.emp_id
AND pro.id = epp.pro_id
AND epp.project_role_id = per.id )
GROUP BY pro.project_name,TP.WEEK_ENDING_DATE
order by TP.WEEK_ENDING_DATE asc
Thanks
SudhirHi,
You can't adjust the chart dimensions dynamically without constructing the whole thing dynamically. You can set "Use Custom XML" to Yes and then change the Height and Width settings of the chart_area tag. Labels can be rotated by setting "Labels Rotation" in the Display Settings section of the Chart Attributes to either 90 or 270.
Andy -
Line Graph will be broken on the different lines issue
Hi, While I create a line graph which Horizontal Axis is date, if just has one line then the line is a continuous line from start date to end date,
but if have more than 2 lines and if these lines do not have values on one same date then these lines will be broken
my question is does this correct ? Our requirement is that these lines should be continuous, can the line graph do that ?Your post is unclear, but I think you want to do the following:
Acquire 2D intensity data from a CCD array and plot it on an intensity graph
Draw two lines to delineate an area of interest
Integrate the values of the CCD between these two lines
This is relatively straightforward, but you will need a more complex architecture than the one you currently have. You will need to use the event structure and probably should have a task handling loop, as well. This architecture is known by several things, but "event-driven state machine" is probably the most common. Search these forums for that phrase and you will get lots of information.
For your particular problem:
In your event structure, you will need events to handle drawing the line (could be mouse or button/parameter driven, or both), events to calculate the integral, and the usual start/stop/data acquisition things. Note that all these events should only generate commands for your command processor/state machine to handle. These will be send via queue.
In your queue-driven state machine / task handler, you will need a shift register to hold such variables as the line data (both of them), local copy of the intensity graph data, etc.
The different frames of the case statement (or dynamically dispatched VIs if you go the object oriented route) do the actual work.
You should learn about the event structure and queue driven state machines before starting this. Start with the LabVIEW help, then search these forums for additional info. For example, I believe altenbach posted a demo awhile back of the event structure in which he drew a polygonal line.
Good luck. Let us know if you need more info.
This account is no longer active. Contact ShadesOfGray for current posts and information. -
Dear All,
We have genrated static line graphs by using JFree, now we are planning to generate them dynamically , which will read x,y quadrants from database , please guide me on the same.
Thanks in advance,
SumanNandy_09 wrote:
I dint c any rude person than u.I suppose you don't have a mirror handy.
N i hardly like to waste my time in arguing with people like u.Oh, but you just did! Do you often do things that you "hardly like"?
Be lilttle polite n helpful for the new users.I am, to those who deserve it.
Never expected I would come across people like u in Suns forum.Many would be happy not to come across people like you here..
Goodbye n thanks for ur help (i.e. nothing)You get what you deserve.
db -
Creating a 3 line graph report
Need help with creating a 3 line graph - need to be able to plot 3rd line of data without displaying a legend and use a dynamic tag label for the line. Thanks
You can create two graphs with the same horizontal (and if necessary vertical) scale, and make them occupy the same space on the report, one under another.
On one report, put your 3rd graph line, and remove any visible text, gridlines etc, so you basically just have the axes lines and the graph line.
On the top report, make the background transparent, so both graphs are visible (Chart Expert->Options->Transparent Background). -
How to draw cumulative line graph over the stacked bar chart?(SSRS)
Hello,
I need your help to draw a cumulative line graph over this bar chart.
I need your help to draw a cumulative line graph over this bar chart in SSRS.
The dimension (Category Group) is "Hour" in this case. and expression is sum of two distinct values like 'Y' and 'N' in Activity column(Series Groups). The sum(Activity=Y) in green color and sum(Activity='N') in Red color.
I require to draw a cumulative line graph in this same chart, that should give the result of cumulative Sum(Activity) for each hour?? I mean sum of (Y+N) for each hour and that should be cumulative over the hour.
I mean sum of (Y+N) for each hour and that should be cumulative over the hour.
SSRS Version details:
Microsoft SQL Server Reporting Services Designers
Version 10.50.1600.1
--SivaHi Siva,
It seems that you need to verify your email address to post images, etc
Besides, Microsoft® SQL Server™ 2008 Reporting Services: Step by Step is a good choice to you. With STEP BY STEP, you work at your own pace through hands-on, learn-by-doing exercises. A companion CD includes data sets and sample code. You can download
it from this link http://my.safaribooksonline.com/9780735626041 Click the Extras, you can get the samples and database from Supplemental Content.
And there are vast of valuable articles and SQL Server Reporting Services Books Online in MSDN ,you can click these link to begin your learning journey, SQL Server Reporting Services 2008 Books Online:
http://msdn.microsoft.com/en-us/library/ms159106(v=SQL.100).aspx
Besides these, there are still many valuable videos in Microsoft Webcast, click this link
https://msevents.microsoft.com/cui/SearchDisplay.aspx?culture=en-US#culture=en-US;eventType=0;sortKey=;sortOrder=;pageEvent=false;hdnInitialCount=;searchcontrol=yes;kwdAny=Reporting%20service to register with a windows live ID, then download the ones you
want.
Hope this helps.
Regards,
Charlie Liao
TechNet Community Support -
Hi, i need help in plotting a simple line graph showing the x&y axis and has to plot 3 different lines in the same graph.I have written a program and i need to implement this graph in it.Is there any tutorial for plotting line graphs,i mean steps included.
Please help!You describe your need, but not where it originates from.
Is it a programming assignment? If so, I hope this is not your chosen major, as you will fail because you are a non-resourceful plagarist.
Do you need to simply graph some data? Use an existing package. There are free ones somewhere.
What do you mean "i have written a program and i need to implement this graph in it"? If you wrote the program, wouldn't you be done?
Enjoy programming -
Help needed in plotting line graph!
Hi i need help in plotting a line graph complete with both axes shown,plus the legend on the side shown.
Pls help!!!!
rgdsHere's a simple line graph applet I did some time backimport java.awt.*;
public class LineGraff extends java.applet.Applet{
double []toGraff = {6.0, -14.0, -164.0, -210.0, 108.0, 770.0,
1354.0, 896.0, -572.0, -1348.0, -780.0, -108.0};
double []numsFromFile = {6.0, -14.0, -164.0, -210.0, 108.0, 770.0,
1354.0, 896.0, -572.0, -1348.0, -780.0, -108.0};
int max, min, size, Hscale;
double Vscale;
public void init(){
size = numsFromFile.length-1;
java.util.Arrays.sort(numsFromFile);
max = (int) numsFromFile[size];
min = (int) numsFromFile[0];
Vscale = max-min;
Vscale = 200/Vscale;
Hscale = Math.round(300/size);
public void paint(Graphics g) {
g.setFont(new Font("Arial",0,14));
g.drawString("Example app: drawing a graph from a double array",25,18);
g.setFont(new Font("Arial",0,10));
g.setColor(Color.blue);
g.fillRect(10,20,365,230);
g.setColor(Color.cyan);
g.drawLine(25,25,25,225);
g.drawLine(25,140,330,140);
g.setColor(Color.white);
int intA = 30, intB = 0, intC = 0;
int intD = (int) (Math.round(140 - (Vscale * toGraff[0])));
for(int i=1; i <= size; i++) {
intC = intA + Hscale;
intB = intD;
intD = (int) (Math.round(140 - (Vscale * toGraff[ i ])));
g.drawLine(intA, intB, intC, intD);
if(toGraff[ i ] > 0)
g.drawString(Double.toString(toGraff[ i-1 ]), intA+6, intB-3);
else
g.drawString(Double.toString(toGraff[ i-1 ]), intA+6, intB+8);
intA += Hscale;
g.drawString(Double.toString(toGraff[size]), intA+6, intD-3);
} -
How do I change the line color in a line graph?
I used Illustrator to create a line graph. (Not my desired option as I normally import them from R and then edit, but the textbook wanted to show that you can create graphs and edit them in Illustrator)
Anyway, I did all of the editing except that I can't change the color of the line. My assignment requires me to match the textbook example and the textbook does not provide instructions on how to do it. I've done just about any method I can think of and the line still stays light gray. I'm almost willing to just give up and lose the points but something as simple as color can't be this hard, right? Right?Whenever I try to shift+direct select it thinks I want to move the line, so as I shift + direct select and drag my mouse across the line (to highlight it all) it moves a chunk of the line and turns it into a near perpendicular line.
I found the appearance window, it just says "Path" (the color I want it to be that it's not)
"Stroke" 4pt
"Fill" (the color I want it to be that it's not)
"Opacity": Default
And some other buttons. I think I'll try the help line tomorrow, I know I saw a customer service number somewhere and I'm only here because the chat was unavailable. This is only one of my 3 problems with my assignment so I'll search here for answers to the other two. Learning new things is rarely fun. -
11.1.1.5 - Measure labels are appearing in legend (line graph)
I've created a line graph in 11.1.1.5. My legend is showing a combination of the column value and the measure name (e.g. Web Sales, Direct Sales, Retail Sales). I want my legend to simply say Web, Direct, and Retail, without the appended 'Sales' measure label.
The Measure Labels tile is currently residing in the Vary Color By (Horizontal Axis) zone, along with the legend column, so I guess it makes sense that the legend column and the measure labels would both show up in the legend (although I don't think that was the case in 11.1.1.3). However, there doesn't appear to be any place into which I can relocate the Measure Labels tile so that the word Sales DOESN'T appear on the line graph. If I move the Measures Labels tile into Graph Prompts, Sections, or Group By (Horizontal Axis), the word Sales appears in those locations. If I attempt to move that tile into the Lines (Vertical Axis) box, or into the Excluded box, it won't allow being dropped there.
Switching between line, bar, and area graphs reveals the same problem in all graph types.
Is there any way to supress the display of measure labels on graphs in 11.1.1.5?Hi Paul,
This is the feature in 11g obiee displaying the Measue heading and dimension value... like u said right Web Sales...and so on.
Here in u case web is the value of dimension and Sales is heading of a measure.
One way is if u are not using any dimension apart from 1 dim and fact u can put measure labels in the group by axis and dimension column in the show in legend section then it will give u only web.
But if u have 2 dimension then we have to put this measure labels with either one of the dimensions in this case heading of the measure wil display.
Thanks
Subhash -
Marker Shape in Legend - Line Graph
Hello,
I have recently upgraded from 10g Release 1 to 10g Release 2.
I am using a line graph. In Release 1, the data marker shapes show up in the legend. In Release 2, they don't. In Graph.xml, I have set the Graph element to have the attribute markerShapeInLegend="true".
Does anybody else have this problem and/or know of a solution?
Thank you.Hi Paul,
This is the feature in 11g obiee displaying the Measue heading and dimension value... like u said right Web Sales...and so on.
Here in u case web is the value of dimension and Sales is heading of a measure.
One way is if u are not using any dimension apart from 1 dim and fact u can put measure labels in the group by axis and dimension column in the show in legend section then it will give u only web.
But if u have 2 dimension then we have to put this measure labels with either one of the dimensions in this case heading of the measure wil display.
Thanks
Subhash -
Hi Experts,
Can anybody tell me how to print line graph in SAP. I do not want use ALV print function for graph generation.
Here I am attaching you sample program for your reference. Name of the program is GFW_PROG_PRES_SHOW_MULT.
Thanks in Advance.
Regards,
Shaik.Hi Meera,
you can use FM "GRAPH_MATRIX_3D' to print graphs. See if this works out good for your.
Simple code to use this would be as follows.
DATA: BEGIN OF itab_data OCCURS 0,
dataname(15),
quantity1 TYPE i,
quantity2 TYPE i,
quantity3 TYPE i,
END OF itab_data,
BEGIN OF itab_options OCCURS 0,
option(20),
END OF itab_options.
itab_data-dataname = 'Electricity'.
itab_data-quantity1 = 55.
itab_data-quantity2 = 62.
itab_data-quantity3 = 59.
APPEND itab_data.
itab_data-dataname = 'Gas'.
itab_data-quantity1 = 35.
itab_data-quantity2 = 52.
itab_data-quantity3 = 44.
APPEND itab_data.
itab_data-dataname = 'Water'.
itab_data-quantity1 = 18.
itab_data-quantity2 = 22.
itab_data-quantity3 = 19.
APPEND itab_data.
CALL FUNCTION 'GRAPH_MATRIX_3D'
EXPORTING
col1 = 'Jan'
col2 = 'Feb'
col3 = 'Mar'
titl = 'Gráfico Teste - Carlos'
TABLES
data = itab_data
opts = itab_options
EXCEPTIONS
OTHERS = 1.
Hope this helps.
Thanks
Sumit
Maybe you are looking for
-
Formula Variable in Bex , Urgent
Hi Experts, I have created a formula variable on 0Material with replacement path as processing type. I am using this formula variable in a formula that i have created. The formula works fine. However , when i create another formul
-
Best way to upgrade illustrator and photoshop cs2 and purchase indesign
Need to upgrade my os and software. I'm running illustrator and photoshop cs2 and want to purchase indesign. what is the best way to do this?
-
Previously purchased quick time pro and lost it
I purchased Quick Time Pro for Windows 7 and then lost it when my computer crashed. I have recovered the product key from my Apple account but I can't figure out how to use the key to recover my product. It just keeps asking me to buy the program a
-
Can anyone give me some documents for data cluster
Hi, can anyone give me some documents for data cluster? ths! regards!
-
HT204053 I have created a apple id but while signing in the setting it showing 403 error
I have created a apple id but while signing in the setting it showing 403 error