<?xml version="1.0"?>
<OriginStorage FileName="D:\OriginPro80\Samples\Programming Guide\X-Functions\xyrange_to_new_yxrange_ex.OXF" Display="652" Label="System: xyrange_to_new_yxrange_ex"><XFname NodeID="11" Label="Name" DataID="300">xyrange_to_new_yxrange_ex</XFname><xFdescription NodeID="11" Label="Description" DataID="310"></xFdescription><attachTo NodeID="13" Label="Attach to Origin Object" Combo="None|Auto|Column|Sheet/Layer|Book/Graph" DataID="320">1</attachTo><UsageCtxt NodeID="268435456" Label="Usage Context" DataID="329"><LabTalk NodeID="10" Label="Labtalk" DataID="357">1.</LabTalk><WksSel NodeID="10" Label="Worksheet Selection" DataID="350">0.</WksSel><WksSel NodeID="10" Label="Worksheet Selection Change" DataID="355">0.</WksSel><WksSel NodeID="10" Label="Worksheet Selection Tracking" DataID="356">0.</WksSel><GrObj NodeID="268435456" Label="Graphic Object Events" DataID="330" Use="0"><InitAnchors NodeID="10" Label="Initialization" DataID="339">1.</InitAnchors><Move NodeID="10" Label="Move" DataID="331">1.</Move><Moving NodeID="10" Label="Moving" DataID="332">0.</Moving><Resize NodeID="10" Label="Resize" DataID="333">0.</Resize><Resizing NodeID="10" Label="Resizing" DataID="334">0.</Resizing><Delete NodeID="10" Label="Delete" DataID="335">0.</Delete><Select NodeID="10" Label="Select" DataID="336">0.</Select><Unselect NodeID="10" Label="Unselect" DataID="337">0.</Unselect><BtnClick NodeID="10" Label="Button Click" DataID="338">0.</BtnClick><Rotate NodeID="10" Label="Rotate" DataID="340">0.</Rotate><Rotating NodeID="10" Label="Rotating" DataID="341">0.</Rotating><Skew NodeID="10" Label="Skew" DataID="342">0.</Skew><Skewing NodeID="10" Label="Skewing" DataID="343">0.</Skewing><EditEv NodeID="10" Label="Edit" DataID="344">0.</EditEv><Editing NodeID="10" Label="Editing" DataID="345">0.</Editing></GrObj><ToXFHeader NodeID="10" Label="Declare in xf.h" DataID="358">0.</ToXFHeader></UsageCtxt><vars NodeID="268435456" Label="Variables" Branch="1" MoveRows="" EditCol="1|1|1"><v1 NodeID="268435456" _XFUNCTION_VAR="1" RepeatID="1" Branch="1"><name NodeID="11" Label="Name" DataID="10">in</name><description NodeID="11" Label="Description" DataID="20"></description><io NodeID="13" Label="Input/Output" Combo="Input|Output|Input/Output" DataID="30" Handler="116810768">0</io><type NodeID="11" Label="Data Type" Combo="double|string|int|vector|Range|XYRange|XYZRange|matrix|MatrixObject|ButtonInfo|LineInfo|TextInfo|EventInfo|MarkerInfo" DataID="40" Handler="116810768">XYRange</type><valdata NodeID="44" Label="Data" DataID="50" DChng="1"><X NodeID="35" DataID="51">Col(1)</X><Y NodeID="35" DataID="52">Col(2)</Y><ED NodeID="35" DataID="53"></ED></valdata><Context NodeID="268435456" Label="Context"/><Data NodeID="268435456" Label="New Output Data" DataID="911" Branch="2048" Show="0"><Book NodeID="11" Label="Book" Combo="&lt;active&gt;|&lt;new&gt;|&lt;source&gt;|&lt;existing&gt;..." DataID="903" Handler="116145272">&lt;new&gt;</Book><Sheet NodeID="11" Label="Sheet" Combo="&lt;active&gt;|&lt;new&gt;" DataID="904" Handler="113838192" Enable="1">&lt;new&gt;</Sheet><ColumnName NodeID="11" Label="Column" DataID="912">Default</ColumnName><XColumnName NodeID="11" Label="XColumn" DataID="913">X</XColumnName><YColumnName NodeID="11" Label="YColumn" DataID="914">Y</YColumnName><ZColumnName NodeID="11" Label="ZColumn" DataID="915">Z</ZColumnName></Data></v1><v2 NodeID="268435456" _XFUNCTION_VAR="1" RepeatID="2" Branch="1"><name NodeID="11" Label="Name" DataID="10">out</name><description NodeID="11" Label="Description" DataID="20"></description><io NodeID="13" Label="Input/Output" Combo="Input|Output|Input/Output" DataID="30" Handler="116810768">1</io><type NodeID="11" Label="Data Type" Combo="double|string|int|vector|Range|XYRange|XYZRange|matrix|MatrixObject|ButtonInfo|LineInfo|TextInfo|EventInfo|MarkerInfo" DataID="40" Handler="116810768">XYRange</type><valdata NodeID="44" Label="Data" DataID="50"><X NodeID="35" DataID="51">&lt;new&gt;</X><Y NodeID="35" DataID="52">&lt;new&gt;</Y><ED NodeID="35" DataID="53">&lt;new&gt;</ED></valdata><Context NodeID="268435456" Label="Context"/><Data NodeID="268435456" Label="New Output Data" DataID="911" Branch="2048" Show="1"><Book NodeID="11" Label="Book" Combo="&lt;active&gt;|&lt;new&gt;|&lt;source&gt;|&lt;existing&gt;..." DataID="903" Handler="116145272" Show="1">&lt;new&gt;</Book><Sheet NodeID="11" Label="Sheet" Combo="&lt;active&gt;|&lt;new&gt;" DataID="904" Handler="113838192" Show="1" Enable="1">&lt;new&gt;</Sheet><ColumnName NodeID="11" Label="Column" DataID="912" Show="0">Default</ColumnName><XColumnName NodeID="11" Label="XColumn" DataID="913" Show="1">X</XColumnName><YColumnName NodeID="11" Label="YColumn" DataID="914" Show="1">Y</YColumnName><ZColumnName NodeID="11" Label="ZColumn" DataID="915" Show="0">Z</ZColumnName></Data></v2></vars><header NodeID="45" Label="Header" DataID="323" RowHeightRange="3-15"><![CDATA[#include <origin.h>
]]></header><code NodeID="45" Label="Expression" DataID="325" RowHeightRange="5-20"><![CDATA[// Swap X and Y data of XYRange
vector vx, vy;
in.GetData(vy, vx); // Get data from XYRange into vectors vx and vy
out.SetData(&vx, &vy); // Write data in vectors vx and vy out to a different XYRange]]></code></OriginStorage>
