<?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 Converting days to years using proc format in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798863#M39293</link>
    <description>&lt;P&gt;I was able to create a new variable called 'Age' which = number of years of age the person was at the time of symptoms onset using this code:&lt;/P&gt;
&lt;PRE&gt;data Age;&lt;BR /&gt;	set HospitalDays;&lt;BR /&gt;	Age = (dateSymptoms - DOB);&lt;BR /&gt;	format Age years. &lt;BR /&gt;	run;&lt;/PRE&gt;
&lt;P&gt;It worked perfectly! however, even when I used format Age years. the numbers are displayed as days from DOB to symptoms vs years. &amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 26 Feb 2022 16:40:50 GMT</pubDate>
    <dc:creator>saza</dc:creator>
    <dc:date>2022-02-26T16:40:50Z</dc:date>
    <item>
      <title>Converting days to years using proc format</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798863#M39293</link>
      <description>&lt;P&gt;I was able to create a new variable called 'Age' which = number of years of age the person was at the time of symptoms onset using this code:&lt;/P&gt;
&lt;PRE&gt;data Age;&lt;BR /&gt;	set HospitalDays;&lt;BR /&gt;	Age = (dateSymptoms - DOB);&lt;BR /&gt;	format Age years. &lt;BR /&gt;	run;&lt;/PRE&gt;
&lt;P&gt;It worked perfectly! however, even when I used format Age years. the numbers are displayed as days from DOB to symptoms vs years. &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 26 Feb 2022 16:40:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798863#M39293</guid>
      <dc:creator>saza</dc:creator>
      <dc:date>2022-02-26T16:40:50Z</dc:date>
    </item>
    <item>
      <title>Re: Converting days to years using proc format</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798866#M39294</link>
      <description>&lt;P&gt;Formats won't get the job done in this case. They can display dates as year, but your variable Age is not a date.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In an earlier thread, you said your lab asked you to use a specific function to do this. What function was it, and did you try that? If not, please try it.&lt;/P&gt;</description>
      <pubDate>Sat, 26 Feb 2022 17:11:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798866#M39294</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2022-02-26T17:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: Converting days to years using proc format</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798867#M39295</link>
      <description>data Age;&lt;BR /&gt;	set HospitalDays;&lt;BR /&gt;	Age = yrdif(DOB, dateSymptoms); &lt;BR /&gt;	run;&lt;BR /&gt;&lt;BR /&gt;Hi Paige! I just needed to tweak my proc transpose to make the rest of my code work. the code above worked to help me some for the years,</description>
      <pubDate>Sat, 26 Feb 2022 17:15:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Converting-days-to-years-using-proc-format/m-p/798867#M39295</guid>
      <dc:creator>saza</dc:creator>
      <dc:date>2022-02-26T17:15:59Z</dc:date>
    </item>
  </channel>
</rss>

