Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I have an excel file I am trying to import into Mathematica. It is in the format of variables names in the first row of each column and then the data underneath. One of the columns specifies hospitals, so each row has observations for each hospital. There are approximately 800 columns and 400 hospitals. Some of the variables are strings, such as hospital names. But I could delete those in Excel if I had to. I imported it and the text filled the screen. I saw there was a program called Link for Excel, but $250 is a lot of money for a student. I then tried ListView and the table was all wrong. The variable names were in the first column. It seems like it was displaying rows as columns. I want to make sure what is imported is a matrix so we can run some linear programming. Thanks so much for your help in advance!

share|improve this question
    
Take a look at Import[] ... What do you mean by " I imported it and the text filled the screen"? –  belisarius Jun 17 '13 at 22:59
    
Use the Transpose[] function to convert between rows and columns. –  shrx Jun 17 '13 at 23:01
add comment

1 Answer 1

How about:

 data = Import[file.xls, {"Data", 1}]
share|improve this answer
1  
And if you don't want to see the data "fill the screen" when you do the import, add a semi-colon at the end: data = Import[file.xls, {"Data", 1}]; –  bill s Jun 18 '13 at 2:09
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.