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

Hi, 

 

I need help on adjusting alignment for footnotes. I have got the following codes currently: 

TITLE j=left "Jadual B1 : Jumlah penduduk mengikut kumpulan etnik, kawasan pihak berkuasa tempa'tan dan negeri, Malaysia, 2010";
Title2 font=bold italic j=left "Table   B1 : Total population by ethnic group, local authority area and state, Malaysia, 2010";
title3 " ";
title4 j=left "Negeri : NEGERI SEMBILAN";
title5 font=bold italic j=left "State";

proc tabulate data=WORK.DOSM order=data;
	where not missing(NEW_ETHNICITY);
	class DISTRICT NEW_ETHNICITY NEW_CITIZENSHIP /Missing;
	classlev NEW_ETHNICITY;
	CLASSLEV NEW_citizenship;
	classlev district;
	var ID;
	table ALL DISTRICT=' ', ALL NEW_ETHNICITY='Warganegara Malaysia
Malaysian citizens' ALL 
		NEW_CITIZENSHIP='Bukan Warganegara Malaysia *Non-   Malaysian citizens *' 
		/Box='Daerah Pentadbiran/Kawasan Pihak Berkuasa Tempatan
										Administrative District/Local Authority Area' row=float MISSTEXT='0';
	keylabel N=' ';
	keylabel all='Jumlah Total';
	footnote font=arial bold j=left "Nota" font=arial bold italic "/Note";
	footnote2 j=l   f='ARIAL amt/bold' "Angka-angka di atas tidak disesuaikan untuk kurang penghitungan.";
run;

And i get the following result: 

 

Capture2.PNG

 

However, i need the footnote2 first word 'Angka' to start after Note/Nota as per the following example: 

 

Capture.PNG

 

Could anyone please help me on this?

 

Thank you. 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Ksharp
Super User

 

ods escapechar='~';
proc tabulate ........
..............

footnote
font=arial bold j=left "Nota" font=arial bold italic "/Note"; footnote2 j=l f='~_~_~_~_~_~_~_~_~_ARIAL amt/bold' "Angka-angka di atas tidak disesuaikan untuk kurang penghitungan.";

 

View solution in original post

7 REPLIES 7
RW9
Diamond | Level 26 RW9
Diamond | Level 26

There is no automatic way of doing this, valid alignements are left, right, and center.  The simplest method is to add spaces to increment the footnote out to where you want it.  I would also avoid putting footnotes in the proc step, there is no need and it just clutters the proc, and please avoid upper case coding, makes reading the code much harder.

sheren_deep1
Calcite | Level 5

Hi, 

 

Thank for your reply. Can you please explain to me how to  add spaces to increment the footnote? I need the table precisely on this format; hence i need the footnote. 

 

 

RW9
Diamond | Level 26 RW9
Diamond | Level 26

Press the spacebar:

footnote font=arial bold j=left "Nota" font=arial bold italic "/Note";
footnote2 j=l   f='ARIAL amt/bold' "          Angka-angka di atas tidak disesuaikan untuk kurang penghitungan.";

You may have to add or remove a space to get the alignment.  If you have to do this a lot, consider aligning the footnotes rather than offsettting them somewhat.  Otherwise you may need a cat(repeat(" ",lengthn(previousfootnote)-1),"Your new footnote")

sheren_deep1
Calcite | Level 5

Hi, 

 

I have actually tried adding blank spaces before the first letter. However, this does not work for me :(. Any other suggestion?

 

 

Thanks 

RW9
Diamond | Level 26 RW9
Diamond | Level 26

"However, this does not work for me" - does not tell me anything.  What did not work, was it not aligned, did it crash?  As I said there is no automatic alignment for what you are asking (as its not a standard alignment), so you need to fix it in yourself somehow.  

Ksharp
Super User

 

ods escapechar='~';
proc tabulate ........
..............

footnote
font=arial bold j=left "Nota" font=arial bold italic "/Note"; footnote2 j=l f='~_~_~_~_~_~_~_~_~_ARIAL amt/bold' "Angka-angka di atas tidak disesuaikan untuk kurang penghitungan.";

 

sheren_deep1
Calcite | Level 5

Hi, 

 

It works. Thank you for the help. 🙂 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 7 replies
  • 1940 views
  • 0 likes
  • 3 in conversation