Multiple Y Axes Reference

How do I reference a plot to the second Y axis?
Using the example Multiple Y Axis....
I want Plot 2 to reference the seconds Y axis, however, it always references the first Y axis
void CMultipleYAxisDlg:nGenerateData()
int i;
CNiReal64Vector RedData(100);
CNiReal64Vector MagentaData(100);
CNiReal64Vector WhiteData(100);
for (i = 0; i < 100; i++)
MagentaData[i] = -25;
WhiteData[i] = 125; // always references 1st Y axis on right side
RedData[i] = 700;
m_Graph.GetPlots().Item(1).PlotY(MagentaData,0,1);
m_Graph.GetPlots().Item(2).PlotY(WhiteData,0,1);
m_Graph.GetPlots().Item(3).PlotY(RedData,0,1);

The CNiPlot class has a YAxis property whose type is CNiAxis. You should set this property to the axis that you want associated with the plot. For example, assuming your graph has at least two plots and at least two y axes, you could do this:
m_Graph.Plots.Item(2).YAxis = m_graph.Axes.Item(3);
- Elton

Similar Messages

  • Creating a report with multiple Y-axes on one graph

    I currently have a script that will create a report with either 1, 2, or 3 graphs and has the ability to have four graphs per plot.  I would like to add functionality to this script by making the Y-axis on the graphs have multiple Y-axes.  How can I programmatically create a graph with multiple Y-axes?

    To create an new axis system use the command GraphObjNew, eg:
    Call GraphObjNew("2D-Axis","2DAxis1")
    Call GraphObjOpen("2DAxis1")        
      D2AxisBackColor = "blue"  
    Call GraphObjClose("2DAxis1") 
    Call PicUpdate
    If you have DIAdem Version 10 you can also create a new y-axis using GraphObjYAxisNew. This command is not available in versions 9.1:
    Call GraphObjOpen("2DAxis1")
    AxisNo = GraphObjYAxisNew("left")
    If AxisNo>0 Then
      Call GraphObjOpen(D2AxisYObj(AxisNo))
      D2AXISYTXT ="My new axis"
      D2AXISYTXTFONT ="Arial"
      D2AXISYTXTCOLOR ="red"
      Call GraphObjClose(D2AxisYObj(AxisNo))
    End If
    Call GraphObjClose("2DAxis1")
    Winfried
    Message Edited by winner on 03-23-2006 03:48 PM

  • How to set property nodes for each of the multiple y-axes?

    In Labview 6i, I have set up multiple y-axes on an xy graph. I want to change certain properties of each of the 2 y-axes independently. I believe I can do this using "property node".
    However, after I have created a property node for the xy graph, I realised that there is only 1 y-axis selectable from the list of properties. How can I set the property of the other y-axis then?
    Thanks for the help!

    I believe there is a property called "active graph"... this allows you to
    select the active graph to apply the property changes to...
    Later...
    meng118230 wrote in message
    news:[email protected]..
    > In Labview 6i, I have set up multiple y-axes on an xy graph. I want to
    > change certain properties of each of the 2 y-axes independently. I
    > believe I can do this using "property node".
    >
    > However, after I have created a property node for the xy graph, I
    > realised that there is only 1 y-axis selectable from the list of
    > properties. How can I set the property of the other y-axis then?
    >
    > Thanks for the help!

  • Multiple X axes in DIAdem 9.1

    Is it possible to have multiple X-axis scales for a 2-D plot in DIAdem 9.1? 
    I have no problem with multiple y axes but I would also like multiple x axes as well.
    Thanks,
    Tom

    Hi Tom,
    Multiple X axes are not supported anywhere in DIAdem 2012, so that's a dead stop.  If you want to overlay multiple curves in VIEW that have different X values, you will need to rescale those X values.  If you're plotting waveforms, this is as easy as multi-selecting the set of N channels you want to change in the Data Portal and editing the waveform start offset property, which will make the property value change you entered once to all N channels selected.  If you have N Y channels that share an X channel, then you just need to rescale the one X channel once with the Linear Scaling function in ANALYSIS.
    Brad Turpin
    DIAdem Product Support Engineer
    National Instruments

  • Multiple y axes overlap

    I have a graph with multiple y axes. I programmatically turn on and off some of the y axes as and when I need them, appropriate to the curves I'm plotting.
    When I created the graph, I placed half the y axes to the left of the plot, and the remainder to the right. However, when I use the yScale.Visible property to show/hide the axes, I get something like this:
    What's happening!? Why are my y-axes overlapped? (please ignore the white box in the plot, that's just me covering up some annotation text)
    Message Edited by Thoric on 07-16-2008 04:05 PM
    Thoric (CLA, CLED, CTD and LabVIEW Champion)
    Attachments:
    multiyaxisgraph.jpg ‏44 KB

    My chart has four axes on the left and four on the right, so you can understand why I want to hide those that aren't used as it gets very busy on there sometimes ! Unfortunately, none can be re-used as there are rare occasions when all eight are needed!
    I've managed to re-create the plot, and also create a hard-coded list defining which side of the plot (left or right) each y-axis is meant to reside. Thus, if LV 'forgets' which side of the plot to draw the y axis, it doesn't matter because I'm now calculating the actual scale position.left property and setting it myself.
    Took a bit of coding up, but seems to work nicely now!
    Thanks for the advice Paul. It's good to know people are out there willing to help!
    (I'd rate your answers but I don't have enough posts to have that privilege yet. sorry)
    Thoric (CLA, CLED, CTD and LabVIEW Champion)

  • Multiple cells that reference one value

    Hey guys -
    Still new to formulas - any help would be appreciated.
    I have a cell on table 1, with the cell value duplicated in other tables / sheets in my document. For example, Cell A1 in tables 2 & 3 is referencing back to table 1, using the formula =Sheet 1 :: Table 1 :: A1.
    Is there a way to change the cell value in tables 2 or 3, and have it change the value in the others? (this would help me, since I have multiple sheets that I have referencing this value, and it would be easier to not have to keep changing sheets to change the value in the original cell, on sheet 1.)
    Thanks
    Jeremy

    Using a script would be easier if the value is typed in a display dialog.
    The main problem is that it would be needed to know the tables ID.
    The OP wrote :
    I have a cell on table 1, with the cell value duplicated in other tables / sheets in my document.
    So, he must tell if every sheets of the document are containing a target table and if the target tables have the same name.
    If the answer to these questions is YES, this skeleton may be used:
    --{code}
    set {dName, sName, tName, rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    tell application "Numbers" to tell document dName
              tell sheet sName to tell table tName
                        set theValue to value of cell rowNum1 of column colNum1
              end tell
              set lesFeuilles to name of sheets
              repeat with s from 1 to count of lesFeuilles
                        set aSheet to item s of lesFeuilles
                        if aSheet is not sName then set value of cell rowNum1 of column colNum1 of table tName of sheet aSheet to theValue as text
              end repeat
    end tell
    --=====
    set { dName, sName, tName,  rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
    on get_SelParams()
              local d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2
              tell application "Numbers" to tell document 1
                        set d_Name to its name
                        set s_Name to ""
                        repeat with i from 1 to the count of sheets
                                  tell sheet i to set maybe to the count of (tables whose selection range is not missing value)
                                  if maybe is not 0 then
                                            set s_Name to name of sheet i
                                            exit repeat
                                  end if -- maybe is not 0
                        end repeat
                        if s_Name is "" then
                                  if my parle_anglais() then
                                            error "No sheet has a selected table embedding at least one selected cell !"
                                  else
                                            error "Aucune feuille ne contient une table ayant au moins une cellule sélectionnée !"
                                  end if
                        end if
                        tell sheet s_Name to tell (first table where selection range is not missing value)
                                  tell selection range
                                            set {top_left, bottom_right} to {name of first cell, name of last cell}
                                  end tell
                                  set t_Name to its name
                                  tell cell top_left to set {row_Num1, col_Num1} to {address of its row, address of its column}
                                  if top_left is bottom_right then
                                            set {row_Num2, col_Num2} to {row_Num1, col_Num1}
                                  else
                                            tell cell bottom_right to set {row_Num2, col_Num2} to {address of its row, address of its column}
                                  end if
                        end tell -- sheet…
                        return {d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2}
              end tell -- Numbers
    end get_SelParams
    --=====
    on parle_anglais()
              return (do shell script "defaults read 'Apple Global Domain' AppleLocale") does not start with "fr_"
    end parle_anglais
    --=====
    --{code}
    CAUTION, we can't apply this scheme if values are dates.
    I already explained why, I will not repeat.
    This is why my preferred choice would be to type the value in the script.
    --{code}
    Grab the parameters defining the selected target cell *)
    set {dName, sName, tName, rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    Type the string *)
    set theValue to text returned of (display dialog "Type the value to insert" default answer "what we are supposed to type")
    Fill the cells with the same reference in every table with the same name in every sheets *)
    tell application "Numbers" to tell document dName
              set lesFeuilles to name of sheets
              repeat with s from 1 to count of lesFeuilles
                        set value of cell rowNum1 of column colNum1 of table tName of sheet (item s of lesFeuilles) to theValue as text
              end repeat
    end tell
    --=====
    set { dName, sName, tName,  rowNum1, colNum1, rowNum2, colNum2} to my get_SelParams()
    tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
    on get_SelParams()
              local d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2
              tell application "Numbers" to tell document 1
                        set d_Name to its name
                        set s_Name to ""
                        repeat with i from 1 to the count of sheets
                                  tell sheet i to set maybe to the count of (tables whose selection range is not missing value)
                                  if maybe is not 0 then
                                            set s_Name to name of sheet i
                                            exit repeat
                                  end if -- maybe is not 0
                        end repeat
                        if s_Name is "" then
                                  if my parle_anglais() then
                                            error "No sheet has a selected table embedding at least one selected cell !"
                                  else
                                            error "Aucune feuille ne contient une table ayant au moins une cellule sélectionnée !"
                                  end if
                        end if
                        tell sheet s_Name to tell (first table where selection range is not missing value)
                                  tell selection range
                                            set {top_left, bottom_right} to {name of first cell, name of last cell}
                                  end tell
                                  set t_Name to its name
                                  tell cell top_left to set {row_Num1, col_Num1} to {address of its row, address of its column}
                                  if top_left is bottom_right then
                                            set {row_Num2, col_Num2} to {row_Num1, col_Num1}
                                  else
                                            tell cell bottom_right to set {row_Num2, col_Num2} to {address of its row, address of its column}
                                  end if
                        end tell -- sheet…
                        return {d_Name, s_Name, t_Name, row_Num1, col_Num1, row_Num2, col_Num2}
              end tell -- Numbers
    end get_SelParams
    --=====
    on parle_anglais()
              return (do shell script "defaults read 'Apple Global Domain' AppleLocale") does not start with "fr_"
    end parle_anglais
    --=====
    --{code}
    Yvan KOENIG (VALLAURIS, France) jeudi 2 février 2012
    iMac 21”5, i7, 2.8 GHz, 12 Gbytes, 1 Tbytes, mac OS X 10.6.8 and 10.7.2
    My Box account  is : http://www.box.com/s/00qnssoyeq2xvc22ra4k

  • Multiple Y Axes

    Hi
    I am using Flex2 and i am developing line charts,DateTime
    with X-Axis and multiple series on Y-Axis, how can i develope
    multiple(more than 2) Y-Axes with different ranges

    Flex 3 supports multiple (more than 2) axes, where we can
    specify horizontal and vertical axis for each series. But Flex 2
    supports a maximum of 2 axes. Second axis can be added using the
    properties secondHorizontalAxis, secondVerticalAxis,
    secondDataProvider and secondSeries

  • How can i copy multiple projects that reference one event without having to duplicate the event over and over for each project?

    Each project has compound and regular media in them, and every time i attempt to duplicate the projects and have them reference one event on the new drive the rest of my media shows up missing and will not reconect. Wondering if anyone has had to tackle this problem. I have a limited amount of space on my Drobo thunderbolt drives and need to optomize it. Thank you

    So i called apple and after a few hours on the phone and them taking control of my computer they pretty much told me they had never seen this before and were sorry they couldnt assist in any way. The long explination is that i work for a company that films their footage in one long take and then sends it to me to cut into segments, i then have to copy these small edits which are all in different projects and the one large event over to a new hard drive to give to a guy to put titles on and then send back to the company. when i do this copy of project final cut X forces me to also duplicate the event leaving me with "event" (fcp1) and so on depending on how many projects there are. When i dont duplicate event and project together the whole project shows up as missing media and final cut X does not recognize that the original footage is being lost and therefor i am not even given the oportunity to reconect media. I have tried all conventional ways of copying and transfering and have an extensive background in editing and have never come across this, but then again this is final cut X and something that i try and stray away from if i have a choice in systems.
    to answer Tony im using copy project and event because it is the only option that works (copy project and used media works as well but only creates more confusion with having to rename files) I would prefer to be able to just copy the first project and event and then be able to source the rest of the project files from the first event i copied over.

  • Moving multiple projects that reference the same one event...

    After a help and advice from several of you here, and watching and rewatching some tutorials, I finally figured out how to properly move/archive projects to an external drive.  But I do have at least one question:
    Say I copy a project to an external drive along with its referenced event(s).  All is well as far as that project concerned, and I want to delete both the project and the event it references from my secondary internal drive.  But I have some other versions of that same project I also want to move from the same secondary internal drive to the same external drive.  Of course, I don't want to duplicate the referenced event again.  So how do I do this?
    From the tutorials, I'm guessing the best way to do this would be to duplicate the projects to the external drive.  Then, if I find I want to use them, I can open them and link them to the same event on the external drive. 
    Is that the best way to do this?  I don't guess there's any way to move several projects that all reference one event to an external drive in a way that automatically links them to that event on the new drive?

    Hi Russ--
    Thanks for the link to the tutorial.  I'll definitely watch it.  It's actually by the same people that did the tutorials I'm using, but it might have some new information or help reinforce things.
    My particular problem was moving over the other project files to go with the event that I already moved.  I didn't know how to link them to that newly-created event on the new drive, but, it turns out it's pretty automatic as long as the event has the same name.

  • Multiple y axes overlay eachother

    I'm working on a program which will allow users to plot up to 5 different channels with indepdnant y axes. I make them visible / invisible depending on how many channels are being plotted.  Unfortunately, the axes start to overlap eachother.  I decided to programmatically fix this
    The code works just fine initially (for preventing the axes from overlaying eachother), but quickly mess up once you start making them visible / invisible.
    Any thoughts / solutions?
    Solved!
    Go to Solution.

    BowenM wrote:
    I'm working on a program which will allow users to plot up to 5 different channels with indepdnant y axes. I make them visible / invisible depending on how many channels are being plotted.  Unfortunately, the axes start to overlap eachother.  I decided to programmatically fix this
     [code snippet not copied here]
    The code works just fine initially (for preventing the axes from overlaying eachother), but quickly mess up once you start making them visible / invisible.
    Any thoughts / solutions?
    Well, a couple of things (okay, three) come to mind. First, you don't need to use two different property nodes inside your for loop if you are referring to the same axis - just use one property node and pull down a second property. That way you won't have a chance of mixing things up.
    Second, you could use a for loop set to only include the axes/plots you want visible with autoscaling N to an array of your visible plots, then your axes would all be spaced identically.
    Third, you could set the plot position and size to move over and shorten as more y axes are made visible, so you take up the same amount of screen real estate for any case.
    Other customizations are possible, but these should get you where you say you want to be.
    Cameron
    To err is human, but to really foul it up requires a computer.
    The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
    Profanity is the one language all programmers know best.
    An expert is someone who has made all the possible mistakes.
    To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):
    LabVIEW Unit 1 - Getting Started
    Learn to Use LabVIEW with MyDAQ

  • Sum GETPIVOTDATA with multiple data item references using Array formula and cell references

    I'm trying to build a single formula referencing a shared pivot table. I would prefer not to create additional pivot tables etc.
    My criteria is basically the sum of multiple items in the pivot table. I am able to add multiple fields by typing item names in manually (see below Claims 1/2/3 etc) however I would also like to add a date range array in, but instead of typing them
    in I'd like to use cell values that can change dynamically, depending on previous options selected.
    My current formula is:
    {=SUM(IFERROR(GETPIVOTDATA("Count",'Settlement Pivots'!$A$1,"Loss Fin Year",$B6,"Scheme","Old Scheme","Month",{[Cell Range/Indirect Here...]},"Team2",{"Claims 1","Claims 2","Claims
    3","Claims 4","Claims 5","Major Claims","Claims Services"},"Scope","Settlement"),0))}
    Is this possible?
    Cheers

    Hi,
    Thank you for posting in the MSDN Forum.
    This forum is for developers disscussing issuses about VBA, VSTO and apps for Office. Since the issue is more relate to the end-user, I suggest you getting more effective response from
    Excel IT pro forum.
    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us.
    Thanks for your understanding.
    Best regards
    Fei
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How do I graph multiple bit values on one time axis?

    I want to graph multiple bit values, all of which will change back and forth from 0 to 1, on the same time axis, but I don't want any visual overlap between the different bit value traces.  Now I could do this by graphing bit one as either 0 or 1, bit 2 as 2 or 3, bit 3 as 4 or 5, etc., but I would really rather have multiple Y axes showing 0 to 1, stacked vertically on the same time (X) axis.
    You could visualize this as multiple pens on a strip chart continuously recording different values.  Each pen has its own vertical area in which it writes, but all pens could be writing data from the same numerical range.
    Hmmm...  I think my description might be roughly as clear as mud, but if anyone out there can figure out what I am asking and has potential solutions, please let me know.
    Thanks!

    Thanks.  I will look at that VI, but I think I have already seen it.  My problem is that I have CAN data coming in for an hour or so, but the time interval between receiving specific CAN arbitration IDs varies, so I want to plot the X axis against specific, varying time values, not a standard dT.  I'm not sure I can do this on a digital graph, but I haven't given up hope yet.
    BTW, I am receiving 8-byte CAN packages.  Some of the bytes represent actual values, but I need to break others up into individual bit values to see error and status flag settings.  Once I break the bytes into bits, I convert from analog values to digital values.

  • Syncing Multiple Text Boxes in a Single Indesign File

    In theory this problem seems rather simple and there should be a simple way to accomplish my task, but every search I've tried for syncing text only explains how to thread text boxes.
    What I need to do is layout a template that is 4UP on the page. Currently, whenever I make any edits to my text I have to copy the change multiple times to reflect the change in each instance of my layout on the page.
    What I'd like to do is sync all my textboxes so that any changes or updates will automatically be reflected in each instance of the layout. In the past I've accomplished this in Illustrator using symbols and instances a symbol, but I've yet to find a simlar method in Indesign.
    Any insight would be greatly appreciated.

    zslash64 wrote:
    I had stumbled cross referencing, but didn't understand I needed a  seperate reference for each paragraph within the text box. This worked  pretty well, however when making changes to the original reference  sources, I found the cross reference would break so by time I updated  and re-linked each reference in every text box it ended up taking more  time than simply copying the original text box 3 times. I guess I'm looking for more of a dynamic solution.
    Thanks for the help!
    Zach Barner
    Hi, Zach:
    Thanks for the feedback. You shouldn't have to relink or update multiple changed cross-references in a document individually.
    I did a test on my suggestion, because x-refs aren't supposed to break completely when source context is changed. I saw that I didn't caution you about deleting the cross-reference marker (AKA "Text Anchor"); when you create a cross-reference to source material, in the same or different documents, InDesign inserts a cross-reference marker at the beginning of the source paragraph. If it's not visible, enable Type > Show Hidden Characters. It looks like a colon character (:) in the layer's indicator color.
    NOTE: InDesign uses the term "Destination" to describe the paragraph that a cross-reference pulls into the cursor position when you insert a cross-reference, and it uses the term "Source" to describe the pulled-in destination paragraph that's displayed at the position where the cross-reference is inserted. This usage derives from the terms used for InDesign hyperlinks, where it makes better sense. Depending on your pre-InDesign experience with cross-references in longhand, typewritten, or other computer applications, you may find it, as I do, counterintuitive. I think of "source" as what you pull in, "destination" as the place where you display what's pulled in, and "reference" as the thing that's pulled in. I also use the term "source document" to describe the document that contains the reference's source, and I use the term "container document" to describe the document that contains the reference (the stuff that's pulled in.)
    So, when you change a cross-reference's source material in the source document, if you take care not to delete the cross-reference markers/text anchors that are created at the beginning of source paragraphs, the references in the container document's Hyperlinks/Cross-references panel display a yellow warning triangle for each changed source, and you can update them in one action.
    Updating the changed cross-references can also be confusing: If no changed (yellow triangle) cross-references are selected in the Hyperlinks / Cross-References panel are selected (highlighted,) whether you use the Update cross-references button at the bottom of the Hyperlinks / Cross-References panel, or the Update Cross-Reference item on the Hyperlinks / Cross-References panel's flyout menu, ALL changed cross-references are updated. However, if one or more changed cross-references in the panel are selected, the update button or menu item updates only the selected references.
    See if this helps simplify your operations.
    HTH
    Regards,
    Peter
    Peter Gold
    KnowHow ProServices

  • Using new Air Disk to host iPhoto library to multiple Macs?

    Just some early thoughts and questions...
    One of my biggest wishes for iPhoto has been to keep all my photos in synch. My wife imports family photos to her iBook, I keep some on my Powerbook and then others make there way to the family iMac. Wouldn't it be great for us all to share the same library? Any edits would not have to be done multiple times to the same photo on other machines, etc...
    With the new ability to have an external HD connected to the new Airport Extreme, it seems that it should be possible to locate your main iPhoto libarary on this shared HD connected to the AE? Would this allow iPhoto running on multiple macs to reference a single iPhoto library on the AE connected external HD? And if so, could each mac call up the photos, edit and import to the library? As opposed to simply sharing the library as iPhoto currently does (which does not allow editing or saving to the other shared library)? I wonder how access speed would be over a wireless network (g or n speed)? Going a step further, what about Aperture?
    Thanks for any thoughts...

    However, if my memory is correct, having a fully editable shared iPhoto library is not possible between users of a single Mac nor using a network drive.
    This article explains how to set up a shared iPhoto library in Mac OS X 10.4 which multiple accounts can see and edit. If the numeric UIDs of the accounts which will be sharing the library are the same, or if the Ignore ownership on this volume box is checked in the disk's Get Info window, you don't need to do anything other than dragging the library over and updating iPhoto's preferences.
    (19520)

  • Multiple calendars and multiple email accounts?

    How can I associate iCal calendars to Apple Mail accounts?
    Let's say I have two email accounts configured in Apple Mail ("home" and "work") and I have two calendars with the sames names. When I add an event to iCal, I want to use the matching email account for sending invitations, depending on which calendar I've selected. Is this possible? Otherwise my private email address might get used for invitations to work events and vice versa.

    Wow, does anyone know how to do this? I really need to have multiple calendars that reference multiple email accounts in iCal... Is there a trick on how to do this? Or, is there a better place to post so Apple puts this feature in the next software release?

Maybe you are looking for