Saturday, 30 July 2016

Creating new codes from one meta code

This is another life saver syntax that I learnt from Minhaj. Some datasets come with only one large code with various information. For example it is common to have PSU code which includes the information about the respondent's location, sex etc.

Here is a syntax that can be modified.

SET OVars Both ONumbers Both TVars Both TNumbers Both.
SET OVars Labels ONumbers Labels TVars Labels TNumbers Labels.

comp province = trunc (psu/100000).
comp temp = trunc (psu/10000).
*comp locality = temp - (province*10).
var lab province 'Province'.
val lab province 1'Punjab' 2'Sindh' 3'NWFP' 4'Balochistan'.

format province (f1.0).
fre province.

In this syntax the point to note is that variable "psu" has 6 characters and the code for "province" is stored in position 1. Hence, it is divided by "10000" which will truncate the last 5 characters. 


awamichat said...
This comment has been removed by a blog administrator.
Packers And Movers Bangalore said...
This comment has been removed by a blog administrator.
Sindhuja Ravi said...

Thanks for sharing the valuable information here. So i think i got some useful information with this content. Thank you and please keep update like this informative details.

SEO Company in chennai

Digital Marketing Company in Chennai

ركن الهدى للخدمات المنزليه said...

شركة تنظيف بالدمام
شركة تسليك مجارى بالدمام
شركة مكافحة حشرات بالدمام
شركة مكافحة النمل الابيض بالدمام
شركة عزل اسطح بالدمام
شركة كشف تسربات المياه بالدمام
شركة نقل عفش بالرياض

obat kuat jakarta said...

thank you for sharing
obat kuat jakarta
obat kuat pria
jual obat kuat
viagra jakarta
viagra asli
viagra usa

Jonna Richard said...

A superior All Assignment Help review offered by this website with the advantage of online support with high proficiency level based on its latest research and information by professional reviews writers. Wide ranges of subjects are covered with separate writers for each subject.

Michael Jones said...

All Assignment Help is a web portal where students get help in making assignments for all the subjects, with the help of our experts. You will get 100% plagiarism free assignment. Expert’s consultation is also available for students. If they have any query they can contact with our experts anytime.