<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to create a data table connected to a graph in SAS Visual Analytics</title>
    <link>https://communities.sas.com/t5/SAS-Visual-Analytics/How-to-create-a-data-table-connected-to-a-graph/m-p/143633#M215</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I have a Query regarding my code for a graph created in SAS.(PFA the html output for the same)&lt;/P&gt;&lt;P&gt;I have created a CBEMA curve graph in Base SAS. This chart generates events (data points) dynamically in a particular time frame. &lt;/P&gt;&lt;P&gt;My program generates an animated gif to show data events occuring dynamically.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Requirement:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;My requirement now is that I want a data table above the graph, populated with the latest event(data point) generated on the graph.&lt;BR /&gt;I managed to generate the table, but as you can see in the attached html output, the table is getting created over the chart. I want the table to be aligned properly above the graph and the chart below it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Code functioning:&lt;/STRONG&gt;&lt;BR /&gt;I have annotated the Cbema curve and the Data table separately in the code and have set both the annotated tables in one table named “anno_all “ and have called it in the proc gchart procedure.&lt;/P&gt;&lt;P&gt;According to my knowledge because of this my table is getting created over the chart. &lt;/P&gt;&lt;P&gt;So I want to know if it’s possible to call both the annotated tables(annocbema and anno_table) separately in the graph?&lt;/P&gt;&lt;P&gt;Is there any other method with which I can achieve my requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pasting below the macro I created to generate the attached graph:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;%macro iterate;&lt;BR /&gt;data _null_;&lt;BR /&gt;if 0 then set work.cbema nobs=nobs;&lt;BR /&gt;call symput ('n',nobs);&lt;BR /&gt;run;&lt;BR /&gt;%do i=1 %to &amp;amp;n;&lt;BR /&gt;data read&amp;amp;i (drop=Account);&lt;BR /&gt;set work.cbema (obs=&amp;amp;i);&lt;BR /&gt;run;&lt;BR /&gt;proc sql print;&lt;BR /&gt;create table events as&lt;BR /&gt;select Duration, Magnitude, Event from read&amp;amp;i;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; quit;&lt;BR /&gt;if Account="read&amp;amp;i";&lt;BR /&gt;data anno_table; set events;&lt;BR /&gt;length text $10;&lt;BR /&gt;function ="frame"; output;&lt;BR /&gt;xsys='3'; ysys='5'; hsys='1'; size=4; when='a'; function='label';&lt;BR /&gt;y=100-_n_*5;&lt;BR /&gt;x=5; position='1'; text=trim(left(Duration)); output;&lt;BR /&gt;x=15; position='2'; text=trim(left(Magnitude)); output;&lt;BR /&gt;x=25; position='3'; text=trim(left(Event)); output;&lt;BR /&gt;run;&lt;BR /&gt;data anno_all; set anno_table annocbema;&lt;BR /&gt;run;&lt;BR /&gt;proc gplot data=read&amp;amp;i; &lt;BR /&gt;plot magnitude*duration / annotate = anno_all haxis = axis1 vaxis = axis2 html=tips1;&lt;BR /&gt;plot2 magnitude*incident / &lt;BR /&gt;haxis = axis1 vaxis = axis2 html=tips1/*noframe*/&lt;BR /&gt; autovref cvref=graydd &lt;BR /&gt; autohref chref=graydd &lt;/P&gt;&lt;P&gt; des="" name="&amp;amp;name" ;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;output;&lt;BR /&gt;%end;&lt;BR /&gt;%mend;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Any kind of help will be appreciated.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/11939i5F64CEDD4D27B057/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="gplot8.gif" title="gplot8.gif" /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 31 Jul 2014 08:28:56 GMT</pubDate>
    <dc:creator>Jeema</dc:creator>
    <dc:date>2014-07-31T08:28:56Z</dc:date>
    <item>
      <title>How to create a data table connected to a graph</title>
      <link>https://communities.sas.com/t5/SAS-Visual-Analytics/How-to-create-a-data-table-connected-to-a-graph/m-p/143633#M215</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I have a Query regarding my code for a graph created in SAS.(PFA the html output for the same)&lt;/P&gt;&lt;P&gt;I have created a CBEMA curve graph in Base SAS. This chart generates events (data points) dynamically in a particular time frame. &lt;/P&gt;&lt;P&gt;My program generates an animated gif to show data events occuring dynamically.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Requirement:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;My requirement now is that I want a data table above the graph, populated with the latest event(data point) generated on the graph.&lt;BR /&gt;I managed to generate the table, but as you can see in the attached html output, the table is getting created over the chart. I want the table to be aligned properly above the graph and the chart below it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Code functioning:&lt;/STRONG&gt;&lt;BR /&gt;I have annotated the Cbema curve and the Data table separately in the code and have set both the annotated tables in one table named “anno_all “ and have called it in the proc gchart procedure.&lt;/P&gt;&lt;P&gt;According to my knowledge because of this my table is getting created over the chart. &lt;/P&gt;&lt;P&gt;So I want to know if it’s possible to call both the annotated tables(annocbema and anno_table) separately in the graph?&lt;/P&gt;&lt;P&gt;Is there any other method with which I can achieve my requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pasting below the macro I created to generate the attached graph:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;%macro iterate;&lt;BR /&gt;data _null_;&lt;BR /&gt;if 0 then set work.cbema nobs=nobs;&lt;BR /&gt;call symput ('n',nobs);&lt;BR /&gt;run;&lt;BR /&gt;%do i=1 %to &amp;amp;n;&lt;BR /&gt;data read&amp;amp;i (drop=Account);&lt;BR /&gt;set work.cbema (obs=&amp;amp;i);&lt;BR /&gt;run;&lt;BR /&gt;proc sql print;&lt;BR /&gt;create table events as&lt;BR /&gt;select Duration, Magnitude, Event from read&amp;amp;i;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; quit;&lt;BR /&gt;if Account="read&amp;amp;i";&lt;BR /&gt;data anno_table; set events;&lt;BR /&gt;length text $10;&lt;BR /&gt;function ="frame"; output;&lt;BR /&gt;xsys='3'; ysys='5'; hsys='1'; size=4; when='a'; function='label';&lt;BR /&gt;y=100-_n_*5;&lt;BR /&gt;x=5; position='1'; text=trim(left(Duration)); output;&lt;BR /&gt;x=15; position='2'; text=trim(left(Magnitude)); output;&lt;BR /&gt;x=25; position='3'; text=trim(left(Event)); output;&lt;BR /&gt;run;&lt;BR /&gt;data anno_all; set anno_table annocbema;&lt;BR /&gt;run;&lt;BR /&gt;proc gplot data=read&amp;amp;i; &lt;BR /&gt;plot magnitude*duration / annotate = anno_all haxis = axis1 vaxis = axis2 html=tips1;&lt;BR /&gt;plot2 magnitude*incident / &lt;BR /&gt;haxis = axis1 vaxis = axis2 html=tips1/*noframe*/&lt;BR /&gt; autovref cvref=graydd &lt;BR /&gt; autohref chref=graydd &lt;/P&gt;&lt;P&gt; des="" name="&amp;amp;name" ;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;output;&lt;BR /&gt;%end;&lt;BR /&gt;%mend;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Any kind of help will be appreciated.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/11939i5F64CEDD4D27B057/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="gplot8.gif" title="gplot8.gif" /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Jul 2014 08:28:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Visual-Analytics/How-to-create-a-data-table-connected-to-a-graph/m-p/143633#M215</guid>
      <dc:creator>Jeema</dc:creator>
      <dc:date>2014-07-31T08:28:56Z</dc:date>
    </item>
  </channel>
</rss>

