The best and most comprehensive site for SAS Community.
Month: February 2008
Jodha Akbar (Movie review) 2008 -Bollywood Movie
The Oscar nominated director , Ashutosh G (for best Foreign language Movie Lagaan ) casts Hrithik Roshan (one of India’s most beautiful actors) and ex-Miss World Aishwarya Rai Bacchan in this love story of Mughal Emperor Akbar the Great.
First things first – the movie is as historically true as you can expect entertainment movies to be. So much for history.Hrithik and Aishwarya and the other actors more than compensate for the historical in accuracies . Akbar didn’t win all battles by negotiation, but as a descendant of Mongals did use massacres selectively for shock, awe and deft political manouevering.
But the songs are good , the people are lovely and the movie sets sparkle with mughal grandeur . Lots of Bollywood masala, and some inspiration from Troy ,the Hollywood movie. Which is sad actually. Why borrow the climax from the famous Eric Bana /Hector and Brad pitt/achilles contest.
Hrithik and Aishwarya might as well act in a Hollywood movie rather than copy one. their chemistry makes the movie tick, and you might get to see one of the slowest sensual love songs created in the new generation Bollywood.
Watch Jodha Akbar……..good time pass and well worth your ticket money…… but forget the history of both Akbar and Troy and go with lowered expectations…and you will have a reasonably good time.
Good Night Baghdad
Good night Baghdad
We met as soul mates
On Green Zone Island
We left as inmates
From an asylum
And we were sharp
As sharp as knives
And we were so gung ho
To lay down our lives
We came in spastic
Like tameless horses
We left in plastic
As numbered corpses
And we learned fast
To travel and fight
Our armored cars were heavy
But our bellies were tight
We had no home front
We had no one
They sent us John Mccain
They gave us Jessica Simpson
We dug in deep
And shot on sight
And prayed to Jesus Christ
With all of our might
We had video cameras
To shoot the landscape
We passed the hash pipe
And played our Eminem tapes
And it was dark
So dark in our humvee
And we held on to each other
Like brother to brother
We promised our mothers we’d write
And we would all go down together
We said we’d all go down together
Yes we would all go down together
Remember the Sunnis and Shias
Remember the imprisoned Iraqi
They left their childhood
On every acre
And who was wrong?
And who was right?
It didn’t matter in the thick of the fight
We held the day
In the palm
Of our hand
They ruled the night
And the night
Seemed to last as long as six weeks
On Green zone Island
We held the street corners
They held the rooftops
And they were sharp
As sharp as knives
They heard the hum of our convoys
They counted the humvees
And waited for us to arrive
And we would all go down together
We said we’d all go down together
Yes we would all go down together
(with credit to Billy Joel from Good Night Saigon)
Politics in Analytics
Observers of American Electoral politics ,including the current Presidential Campaign would be struck by the sophisticated degree of analytics being involved. This includes the following –
1) Segmentation of likely percentage Response Rates (vote yes(1) , vote opponent (0)
based on
history of voting
response to stimuli (experience vs change)
ethnicity (black, white ,latino)
income groups (<40,000 USD ,>100000 USD)
education (college educated)
gender (male,female)
geography (rural ,urban,college town)
union affliation
and even coffee (latte drinkers etc 🙂 )
What is striking is that most of these variables like race, gender cannot be used for marketing anything else like credit cards, or financial services on charges of discrimination.
What could be really interesting is if they add credit bureau variables and create logistic models (and not just segmentation). Maybe by 2016, there will be a different category of analytics called Quantitative Political analytics.
–
Another note – What is similar between Ralph Nader , Chaos Theory and Butterfly effect.
Chaos theory states that future results can vary a lot based on slight changes in initial differences.
Butterfly Effect uses this to say a small event like butterfly fluttering in china can cause a big event like typhoon in the US.
Ralph Nader entering the race in 2000 got 90000 votes in Florida, mostly to be siphoned away from Al Gore , who lost Florida and the elections by less than 1000 votes.
Al Gore was against Iraq war since the beginning and had he been President maybe the world would have been greener and no war in Iraq. maybe. No offense meant to anyone.
Howard Dean screaming or Bill Clinton calling Obama as similar to Jesse Jackson’s wins (which is analytically and quantitatively true) or Hillary crying in Iowa , can be similar butterfly effects.No offense meant to anyone.
Comparing Big SpreadSheet A to Big SpreadSheet B
Many organizations have pre-fixed formats for their reporting needs. These formats or Management Information Reports are updated at monthly and quarterly intervals at exactly the same format. However when the spreadsheets become big, analysis becomes tedious in comparing two big spreadsheets due to the sheer number of cells involved.
Using SAS , we can automate this process almost instantly.
We will use proc import to import data from the spreadsheets in such a manner that top row imported consist column headings (sas dataset variables).Note both spreadsheets are exactly in same format.
We will then use proc compare to compare these two datasets.
We can then use the integrated approach to automated reporting in SAS (See Archives- Category Analytics) to further reduce this to a simple batch process.
The relevant codes are –
%let pathfile = “C:\Documents and Settings\” ;
run;
/*CREATING LIBRARY NAME */
libname auto &pathfile;
run;
/*TO CONSERVE SPACE*/
options compress=yes;
/*TO MAKE LOG READABLE */
options macrogen symbolgen;
PROC IMPORT OUT= auto.TEST1
DATAFILE= “C:\Documents and Settings\excel1-full.xls”
DBMS=EXCEL2000 REPLACE;
SHEET=”‘Sales$'”;
/*SPECIFYING WORKSHEET FOR MULTIPLE SHEETS */
GETNAMES=YES;
/*TO TAKE VARIABLE NAMES FROM TOP ROW */
RANGE=”A4:AB2000″;
/*SPECIFYING RANGE OF CELLS IN SPREADSHEET TO BE READ */
RUN;
PROC IMPORT OUT= auto.TEST2
DATAFILE= “C:\Documents and Settings\excel2-full.xls”
DBMS=EXCEL2000 REPLACE;
SHEET=”‘Sales$'”;
/*SPECIFYING WORKSHEET FOR MULTIPLE SHEETS */
GETNAMES=YES;
/*TO TAKE VARIABLE NAMES FROM TOP ROW */
RANGE=”A4:AB2000″;
/*SPECIFYING RANGE OF CELLS IN SPREADSHEET TO BE READ */
RUN;
/* COMPARING THE TWO SPREADSHEETS */
proc compare base=auto.test1 compare=auto.test2;
var
/*SPECIFYING WHAT VARIABLES TO BE COMPARED */
Applications
Approvals
Disbursals
30dayplus
60dayplus
90dayplus
;
with Branch;
/*SPECIFYING VARIABLE FOR COMPARISON
FOR SAME BRANCH IN THIS CASE */
run;
The output will simply compare and compute the cell by cell difference.
You can then use ods to ouput this in another big spreadsheet 🙂
This is particularly relevant in telecommunications and banks, where they need to compare a lot of metrics across timely intervals.
Cutting Office Overheads to Almost Zero
You need to work from home.
Here is what you need-
1) Bandwidth – Broad band
Bandwidth fallback – In case the broad band fails. This should ideally be a wireless kind of modem.
Same goes for your PC s ,backup data online or in your seperate PC .
Have one UPS handy.
2) Communication – Use Skype or Gtalk
3) Email Addresses – In case you do not have your own web server, GMAIL offers most flexibilty because you can use outlook with it . Plus GTALK is loaded with it.
4) Remote Access – Use in Built Features of Microsoft like
a) remote desktop connection (Start -Programs-Accessories-Communication)
b) net meeting (Start- run – type -conf and press enter )
5) Software costs – Use remote applications to connect to Pcs which are pre installed with required software to ensure all software in your org is utilized 24 * 7 .
or use open source and freeware
(like open office ,
google apps,
avg anti virus,
zone alarm firewall,
download accelerator,
ubuntu linux,
mozilla firefox)
Try and test this on 10 % of your staff for three months and note the difference in costs. Then scale up/down depending on experience.
The Air Force
From an Article in Time on US Air Force demands for extra funds.
1) Days earlier, Carlson said that today’s U.S. Air Force “simply cannot fight and win against the fleet of airplanes that have been developed and are flying in India, China, and so forth,” a claim questioned by many experts. But his view has been reinforced by the companies employing 25,000 workers in 44 states building the F-22 — the prime contractor is aerospace giant Lockheed Martin — and their allies in Congress.
Now what is flying in India is a fleet of Mig 21 s that are two decades old, and cant dare take on Pakistan, leave the United States. That’s right, they cant blame the Russians for the money so blame India.
2) And if you thought your wife spent a lot….
More than $1 billion is being sought for 11 passenger planes, seven of them Gulfstream Vs favored by Apple’s Steve Jobs and Sir Elton John (no mention of any Required Force justification here).
Then there’s the line item seeking 100,600 handguns (there are 330,000 people in the Air Force) featuring “improved ergonomic design and higher caliber effectiveness” at $1,157 a pop. The service also wants 210,000 M-4 carbines at $1,747 a clip.