<?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 Re: xnpv excel formula for mip and eg in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688232#M24585</link>
    <description>The data is in sas now. I take it to sas and calculate the colomns like payment, date etc. However, I couldnt calculate colomn for xnpv</description>
    <pubDate>Thu, 01 Oct 2020 14:41:40 GMT</pubDate>
    <dc:creator>Kdumlu</dc:creator>
    <dc:date>2020-10-01T14:41:40Z</dc:date>
    <item>
      <title>xnpv excel formula for mip and eg</title>
      <link>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688157#M24582</link>
      <description>&lt;P&gt;Hello everyone,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a data in excel which calculate XNPV for every payment as you can see in pic.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 589px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/50045i1CD87239C9A774ED/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have to find these values in MIP. However I have so many account with different number of payments and dates. I tried with open formula of XNPV but I cannot get any result.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for help.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Oct 2020 11:03:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688157#M24582</guid>
      <dc:creator>Kdumlu</dc:creator>
      <dc:date>2020-10-01T11:03:36Z</dc:date>
    </item>
    <item>
      <title>Re: xnpv excel formula for mip and eg</title>
      <link>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688214#M24584</link>
      <description>&lt;P&gt;Please post EXCEL related questions to an Excel forum.&lt;/P&gt;
&lt;P&gt;If the data is not in SAS then this question is not related to SAS.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Oct 2020 14:26:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688214#M24584</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-10-01T14:26:02Z</dc:date>
    </item>
    <item>
      <title>Re: xnpv excel formula for mip and eg</title>
      <link>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688232#M24585</link>
      <description>The data is in sas now. I take it to sas and calculate the colomns like payment, date etc. However, I couldnt calculate colomn for xnpv</description>
      <pubDate>Thu, 01 Oct 2020 14:41:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688232#M24585</guid>
      <dc:creator>Kdumlu</dc:creator>
      <dc:date>2020-10-01T14:41:40Z</dc:date>
    </item>
    <item>
      <title>Re: xnpv excel formula for mip and eg</title>
      <link>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688249#M24586</link>
      <description>&lt;P&gt;SAS has function named FINANCE that does many financial calculations. The first parameter is the type of calculation and then follows with the parameters used for the calculation.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Somevar = Finance('XNPV',rate, &amp;lt;values&amp;gt;,&amp;lt;dates&amp;gt;);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;An example from the documentation:&lt;/P&gt;
&lt;DIV class="xis-refDictEntry"&gt;
&lt;DIV id="n02u15conwodnjn1c55spjig8dgd" class="xis-exampleBlock"&gt;
&lt;DIV id="p0vldtvkeoy0w4n13qqcb1yflrgy" class="xis-example"&gt;
&lt;DIV id="n0tw7rcwooqzxzn1ddb7v50xffos" class="xis-paragraph"&gt;
&lt;PRE class="xis-codeFragment"&gt;data _null_;
   r=.09;
   v1=−10000; d1=mdy(1, 1, 2008);
   v2=2750; d2=mdy(3, 1, 2008);
   v3=4250; d3=mdy(10, 30, 2008);
   v4=3250; d4=mdy(2, 15, 2009);
   v5=2750; d5=mdy(4, 1, 2009);
   r=finance('xnpv', r, v1, v2, v3, v4, v5, d1, d2, d3, d4, d5);
   put r=;
run;&lt;/PRE&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;To use variables then all the matching value and date pairs must be on the same record, which likely means that you need to reshape your data (since you haven't shown any I have to assume you have it similar to your Excel example).&lt;/P&gt;
&lt;P&gt;This should be doable with proc transpose. The value needs to correspond to the date in order.&lt;/P&gt;
&lt;P&gt;Note that the first value is negative and corresponds to a cost or payment that occurs at the beginning of the investment.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Oct 2020 15:09:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/xnpv-excel-formula-for-mip-and-eg/m-p/688249#M24586</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-10-01T15:09:19Z</dc:date>
    </item>
  </channel>
</rss>

