<?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 SAS /IML: get list and code of all modules executed in SAS/IML Software and Matrix Computations</title>
    <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/SAS-IML-get-list-and-code-of-all-modules-executed/m-p/608259#M4927</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I search for the best way to get accurate information about the modules executed within an IML session.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Lets assume I have the following two session:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc iml;
start module1(a,b);
measure = a+b;
return measure;
finish module1;

start module2(a,b);
measure = module1(a,b) + a#b;
return measure;
finish module2;

store module=_ALL_;
quit;

proc iml;
load;
a = 10;
b = 20;

val = module2(a,b);

print val;
quit;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the second session I would like to get the module (code) definition of module1 and module2, to understand how the calculated value "val" has been calculated.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The real scenario is that I would load the modules from a storage library which I didnt create myself in the first session, but I want to be sure, what code has been exactly executed by executing one function.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the help documemtation of IML there is the topic "Accessing the IMLMLIB Source Code" which talks about the catalog SASHELP.IML. Can I directls access this file from SAS Studio to get a list of functions and the code?&lt;/P&gt;</description>
    <pubDate>Fri, 29 Nov 2019 14:56:19 GMT</pubDate>
    <dc:creator>AThomalla</dc:creator>
    <dc:date>2019-11-29T14:56:19Z</dc:date>
    <item>
      <title>SAS /IML: get list and code of all modules executed</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/SAS-IML-get-list-and-code-of-all-modules-executed/m-p/608259#M4927</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I search for the best way to get accurate information about the modules executed within an IML session.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Lets assume I have the following two session:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc iml;
start module1(a,b);
measure = a+b;
return measure;
finish module1;

start module2(a,b);
measure = module1(a,b) + a#b;
return measure;
finish module2;

store module=_ALL_;
quit;

proc iml;
load;
a = 10;
b = 20;

val = module2(a,b);

print val;
quit;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the second session I would like to get the module (code) definition of module1 and module2, to understand how the calculated value "val" has been calculated.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The real scenario is that I would load the modules from a storage library which I didnt create myself in the first session, but I want to be sure, what code has been exactly executed by executing one function.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the help documemtation of IML there is the topic "Accessing the IMLMLIB Source Code" which talks about the catalog SASHELP.IML. Can I directls access this file from SAS Studio to get a list of functions and the code?&lt;/P&gt;</description>
      <pubDate>Fri, 29 Nov 2019 14:56:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/SAS-IML-get-list-and-code-of-all-modules-executed/m-p/608259#M4927</guid>
      <dc:creator>AThomalla</dc:creator>
      <dc:date>2019-11-29T14:56:19Z</dc:date>
    </item>
    <item>
      <title>Re: SAS /IML: get list and code of all modules executed</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/SAS-IML-get-list-and-code-of-all-modules-executed/m-p/608432#M4929</link>
      <description>&lt;P&gt;&lt;EM&gt;&amp;gt;&amp;nbsp;In the help documemtation of IML there is the topic "Accessing the IMLMLIB Source Code" which talks about the catalog SASHELP.IML. Can I directls access this file from SAS Studio to get a list of functions and the code?&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No, the IMLMLIB is a collection of SAS-written modules, so it does not apply to the user-written modules in your situation.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you STORE a module, it is "compiled" and stored in binary form. There is no way to recover the source code for a LOADed module.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If seeing the source code is important, I suggest keeping the module definition in a text file such as 'module1.sas' and 'module2.sas'. Then you can &lt;A href="https://go.documentation.sas.com/?docsetId=lestmtsref&amp;amp;docsetTarget=p1s3uhhqtscz2sn1otiatbovfn1t.htm&amp;amp;docsetVersion=1.0&amp;amp;locale=en" target="_self"&gt;use the %INCLUDE statement&lt;/A&gt;&amp;nbsp;to read the definitions. If you turn on the SOURCE2 system option, the source is echoed to the log.&lt;/P&gt;</description>
      <pubDate>Sat, 30 Nov 2019 11:33:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/SAS-IML-get-list-and-code-of-all-modules-executed/m-p/608432#M4929</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-11-30T11:33:36Z</dc:date>
    </item>
  </channel>
</rss>

