<?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: Homework Question in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897690#M39927</link>
    <description>&lt;P&gt;The LIBREF you need to use depends on the LIBNAME statement you submitted.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your code you are using the LIBREF of SAS2023.&amp;nbsp; So you need to have submitted a LIBNAME statement that defines SAS2023 to point to the directory (what some might call a "folder") where you uploaded the file.&amp;nbsp; So something like:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname sas2023 "~/homework";&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If you are running SAS on a Unix machine then make sure the name of the file you uploaded is exactly yrbs2017.sas7bdat since Unix filenames are case sensitive and SAS will be looking for a name using only lowercase letters.&lt;/P&gt;</description>
    <pubDate>Sat, 07 Oct 2023 20:55:54 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2023-10-07T20:55:54Z</dc:date>
    <item>
      <title>Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897685#M39921</link>
      <description>&lt;DIV class=""&gt;How do I fix the file error?&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;&lt;DIV class=""&gt;68&lt;/DIV&gt;&lt;DIV class=""&gt;69 data SAS2023.YRBS1;&lt;/DIV&gt;&lt;DIV class=""&gt;70 set SAS2023.YRBS2017;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;STRONG&gt;ERROR: File SAS2023.YRBS2017.DATA does not exist.&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;71 keep q1-q5 q23-q29;&lt;/DIV&gt;&lt;DIV class=""&gt;72 run;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;WARNING: Not all variables in the list q1-q5 were found.&lt;/DIV&gt;&lt;DIV class=""&gt;WARNING: Not all variables in the list q23-q29 were found.&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/DIV&gt;&lt;DIV class=""&gt;WARNING: The data set SAS2023.YRBS1 may be incomplete. When this step was stopped there were 0 observations and 0 variables.&lt;/DIV&gt;&lt;DIV class=""&gt;WARNING: Data set SAS2023.YRBS1 was not replaced because this step was stopped.&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: DATA statement used (Total process time):&lt;/DIV&gt;&lt;DIV class=""&gt;real time 0.01 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;user cpu time 0.00 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;system cpu time 0.00 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;memory 560.96k&lt;/DIV&gt;&lt;DIV class=""&gt;OS Memory 20896.00k&lt;/DIV&gt;&lt;DIV class=""&gt;Timestamp 10/07/2023 07:36:00 PM&lt;/DIV&gt;&lt;DIV class=""&gt;Step Count 24 Switch Count 0&lt;/DIV&gt;&lt;DIV class=""&gt;Page Faults 0&lt;/DIV&gt;&lt;DIV class=""&gt;Page Reclaims 47&lt;/DIV&gt;&lt;DIV class=""&gt;Page Swaps 0&lt;/DIV&gt;&lt;DIV class=""&gt;Voluntary Context Switches 26&lt;/DIV&gt;&lt;DIV class=""&gt;Involuntary Context Switches 0&lt;/DIV&gt;&lt;DIV class=""&gt;Block Input Operations 32&lt;/DIV&gt;&lt;DIV class=""&gt;Block Output Operations 8&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;73&lt;/DIV&gt;&lt;DIV class=""&gt;74 proc contents data=SAS2023.YRBS1; run;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: PROCEDURE CONTENTS used (Total process time):&lt;/DIV&gt;&lt;DIV class=""&gt;real time 0.02 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;user cpu time 0.01 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;system cpu time 0.00 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;memory 1668.96k&lt;/DIV&gt;&lt;DIV class=""&gt;OS Memory 21924.00k&lt;/DIV&gt;&lt;DIV class=""&gt;Timestamp 10/07/2023 07:36:00 PM&lt;/DIV&gt;&lt;DIV class=""&gt;Step Count 25 Switch Count 0&lt;/DIV&gt;&lt;DIV class=""&gt;Page Faults 0&lt;/DIV&gt;&lt;DIV class=""&gt;Page Reclaims 557&lt;/DIV&gt;&lt;DIV class=""&gt;Page Swaps 0&lt;/DIV&gt;&lt;DIV class=""&gt;Voluntary Context Switches 7&lt;/DIV&gt;&lt;DIV class=""&gt;Involuntary Context Switches 0&lt;/DIV&gt;&lt;DIV class=""&gt;Block Input Operations 152&lt;/DIV&gt;&lt;DIV class=""&gt;Block Output Operations 16&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;75&lt;/DIV&gt;&lt;DIV class=""&gt;76 proc format;&lt;/DIV&gt;&lt;DIV class=""&gt;77 value $age '1'= '12 years old or younger' '2' = '13 years old' '3' = '14 years old' '4' = '15 years old' '5' = '16 years&lt;/DIV&gt;&lt;DIV class=""&gt;77 ! old' '6' = '17 years old' '7' = '18 years old';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $AGE has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;78 value $sex '1'= 'Female' '2' = 'Male';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $SEX has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;79 value $grade '1'= '9th grade' '2'= '10th grade' '3'= '11th grade' '4' = '12th grade' '5'= 'Ungraded or other';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $GRADE has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;80 value $hispanic/latino '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $HISPANIC has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;81 value $race '1' = 'American Indian or Alaska Native' '2'= 'Asian' '3'= 'Black' '4'= 'Native Hawaiian or Pacific Islander'&lt;/DIV&gt;&lt;DIV class=""&gt;81 ! '5' = 'White';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $RACE has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;82 value $bullying at school '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $BULLYING has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;83 value $electronic bullying '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $ELECTRONIC has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;84 value $sad or hopeless '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $SAD has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;85 value $considered suicide '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $CONSIDERED has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;86 value $made a suicide plan '1'= 'Yes' '2' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $MADE has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;87 value $attempted suicide '1' = '0 times' '2'= '1 time' '3'= '2 or 3 times' '4'= '4 or 5 times' '5' = '6 or more times';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $ATTEMPTED has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;88 value $injurious suicide '1'= 'Did not' '2' = 'Yes' '3' = 'No';&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: Format $INJURIOUS has been output.&lt;/DIV&gt;&lt;DIV class=""&gt;89 run;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: PROCEDURE FORMAT used (Total process time):&lt;/DIV&gt;&lt;DIV class=""&gt;real time 0.00 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;user cpu time 0.01 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;system cpu time 0.00 seconds&lt;/DIV&gt;&lt;DIV class=""&gt;memory 321.06k&lt;/DIV&gt;&lt;DIV class=""&gt;OS Memory 21664.00k&lt;/DIV&gt;&lt;DIV class=""&gt;Timestamp 10/07/2023 07:36:00 PM&lt;/DIV&gt;&lt;DIV class=""&gt;Step Count 26 Switch Count 2&lt;/DIV&gt;&lt;DIV class=""&gt;Page Faults 0&lt;/DIV&gt;&lt;DIV class=""&gt;Page Reclaims 75&lt;/DIV&gt;&lt;DIV class=""&gt;Page Swaps 0&lt;/DIV&gt;&lt;DIV class=""&gt;Voluntary Context Switches 14&lt;/DIV&gt;&lt;DIV class=""&gt;Involuntary Context Switches 0&lt;/DIV&gt;&lt;DIV class=""&gt;Block Input Operations 0&lt;/DIV&gt;&lt;DIV class=""&gt;Block Output Operations 80&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;90&lt;/DIV&gt;&lt;DIV class=""&gt;91 proc freq data=SAS2023.YRBS1;&lt;/DIV&gt;&lt;DIV class=""&gt;92 table q1 q2 q3 q4 q5 q23 q24 q25 q26 q27 q28 q29;&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q1 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q2 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q3 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q4 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q5 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q23 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q24 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q25 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q26 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q27 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q28 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;ERROR: Variable Q29 not found.&lt;/DIV&gt;&lt;DIV class=""&gt;93 format q1 $age. q2 $sex. q3 $grade. q4 $hispanicorlatino. q5 $race. q23 $bullingatschool. q24 $electronicbullying. q25&lt;/DIV&gt;&lt;DIV class=""&gt;93 ! $sadorhopeless. q26 $consideredsuicide. q27 $madeasuicideplan. q28 $attemptedsuicide. q29 $injurioussuicideattempt.;&lt;/DIV&gt;&lt;DIV class=""&gt;94 run;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/DIV&gt;</description>
      <pubDate>Sat, 07 Oct 2023 19:47:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897685#M39921</guid>
      <dc:creator>Lilly1FAMU</dc:creator>
      <dc:date>2023-10-07T19:47:56Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897686#M39922</link>
      <description>&lt;P&gt;Make sure that the dataset exists. Why do you think it should be there?&lt;/P&gt;</description>
      <pubDate>Sat, 07 Oct 2023 19:57:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897686#M39922</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2023-10-07T19:57:00Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897687#M39923</link>
      <description>&lt;P&gt;I uploaded the file from my canvas. But it is giving me the error because it does not recognize the file. How do I determine what the library name is?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is my code&lt;/P&gt;&lt;PRE&gt;data SAS2023.YRBS1;&lt;BR /&gt;set SAS2023.YRBS2017;&lt;BR /&gt;keep q1-q5 q23-q29;&lt;BR /&gt;run; &lt;BR /&gt;&lt;BR /&gt;proc contents data=SAS2023.YRBS1; run;&lt;BR /&gt;&lt;BR /&gt;proc format;&lt;BR /&gt;value $age '1'= '12 years old or younger' '2' = '13 years old' '3' = '14 years old' '4' = '15 years old' '5' = '16 years old' '6' = '17 years old' '7' = '18 years old';&lt;BR /&gt;value $sex '1'= 'Female' '2' = 'Male';&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Oct 2023 20:03:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897687#M39923</guid>
      <dc:creator>Lilly1FAMU</dc:creator>
      <dc:date>2023-10-07T20:03:16Z</dc:date>
    </item>
    <item>
      <title>Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897688#M39925</link>
      <description>&lt;P&gt;I uploaded the file from my canvas. But it is giving me the error because it does not recognize the file. How do I determine what the library name is?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is my code&lt;/P&gt;&lt;PRE&gt;data SAS2023.YRBS1;&lt;BR /&gt;set SAS2023.YRBS2017;&lt;BR /&gt;keep q1-q5 q23-q29;&lt;BR /&gt;run; &lt;BR /&gt;&lt;BR /&gt;proc contents data=SAS2023.YRBS1; run;&lt;BR /&gt;&lt;BR /&gt;proc format;&lt;BR /&gt;value $age '1'= '12 years old or younger' '2' = '13 years old' '3' = '14 years old' '4' = '15 years old' '5' = '16 years old' '6' = '17 years old' '7' = '18 years old';&lt;BR /&gt;value $sex '1'= 'Female' '2' = 'Male';&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Oct 2023 20:21:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897688#M39925</guid>
      <dc:creator>Lilly1FAMU</dc:creator>
      <dc:date>2023-10-07T20:21:13Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897689#M39926</link>
      <description>&lt;P&gt;For SAS to be able to work with the file, it should be named&lt;/P&gt;
&lt;PRE&gt;yrbs2017.sas7bdat&lt;/PRE&gt;
&lt;P&gt;All lowercase!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or are you trying to use an Excel file with spreadsheets?&lt;/P&gt;</description>
      <pubDate>Sat, 07 Oct 2023 20:53:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897689#M39926</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2023-10-07T20:53:10Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Question</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897690#M39927</link>
      <description>&lt;P&gt;The LIBREF you need to use depends on the LIBNAME statement you submitted.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your code you are using the LIBREF of SAS2023.&amp;nbsp; So you need to have submitted a LIBNAME statement that defines SAS2023 to point to the directory (what some might call a "folder") where you uploaded the file.&amp;nbsp; So something like:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname sas2023 "~/homework";&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If you are running SAS on a Unix machine then make sure the name of the file you uploaded is exactly yrbs2017.sas7bdat since Unix filenames are case sensitive and SAS will be looking for a name using only lowercase letters.&lt;/P&gt;</description>
      <pubDate>Sat, 07 Oct 2023 20:55:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Homework-Question/m-p/897690#M39927</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2023-10-07T20:55:54Z</dc:date>
    </item>
  </channel>
</rss>

