BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
InfoAlisaA
Calcite | Level 5

Hello Everyone,

So I have the following data set that I need to create a format from which is called orion.continent:

                  Continent_

           Obs        ID        Continent_Name

            1         91        North America

            2         93        Europe

            3         94        Africa

            4         95        Asia

            5         96        Australia/Pacific


I used the following code in order to create the continent format:


data continent;

  keep Start Label FmtName;

  retain FmtName 'Continent' ;

  set orion.continent (rename=(Continent_ID=Start Continent_Name=Label));

  run;

proc format library=orion.myfmts cntlin=continent;

run;

proc format library=orion.myfmts fmtlib;

run;

Then my assignment calls for me to run this code and it should run without errors:

data countries;

   set orion.country;

   Continent_Name=put(Continent_ID, Continent.);

run;

proc print data=Countries(obs=10);

   title 'Continent Names';

run;

This is the error that I am continuously getting:

307  data countries;

308     set orion.country;

309     Continent_Name=put(Continent_ID,Continent.);

                                                                     ----------

                                                                     48

ERROR 48-59: The format CONTINENT was not found or could not be loaded.

310  run;

So I am not sure if I am coding this incorrectly or if the code that my assignment has put is incorrect.

Could someone please let me know where this is going wrong?

Thanks,

Alisa

1 ACCEPTED SOLUTION

Accepted Solutions
InfoAlisaA
Calcite | Level 5

Figured it out. Needed to insert:

options fmterr fmtsearch=(orion orion.myfmts);

before my code in order to get this to work.

View solution in original post

1 REPLY 1
InfoAlisaA
Calcite | Level 5

Figured it out. Needed to insert:

options fmterr fmtsearch=(orion orion.myfmts);

before my code in order to get this to work.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 965 views
  • 0 likes
  • 1 in conversation