Загрузка...

How to Import Excel CSV files into SAS 2020

How to import Microsoft Excel CSV into SAS Enterprise Miner. The following files can also imported into SAS Enterprise Miner using the same technique as shown in the video: SAS JMP, SPSS, Stata, Tab-Delimited, Paradox and dBASE files. Importing Data into SAS Enterprise Miner Below is a detailed step by step instructions on how to import data into SAS Enterprise Miner. I've included a sample data file for you work with, cereal.csv (https://bit.ly/3gFZkv4). It's best to watch the video first. 1. Start Enterprise Miner. 2. Create a new project. 3. Right click diagram and select Create Diagram 4. The File Import node is located on the Sample tab of the SAS Enterprise Miner toolbar. Place the File Import node on the diagram. 5. In the File Import property panel make the following changes: i. Set Advanced Advisor = Yes ii. Click the ellipsis button for Import File to open the File Import window. Browse on the File Import window to navigate to the location of cereal.csv file and select the file. Click Open button on the Open window. Select OK on the File Import window to import file. 6. Right click the File Import node and select RUN. 7. Click the ellipsis button in the Variables property to open the Variables window in the File Import node properties panel. 8. This window allows you to verify that all the variables from the cereal.csv file have been imported and have been assigned a role and level. 9. The data can be used now in EM. Saving the Data In order to use the data the next time (once the project has been closed) or to be able to use it in other projects the data must be saved. 1. From the Utility tab drag the Save Data node on the diagram and connect the File Import node to the Save Data node. 2. We need to assign a library in the project startup code editor. 3. Define an SAS library to save the exported data as a SAS data set: a. Ensure that folder where you want to save the library exists. b. In the EM project panel, select your project. c. In the properties panel, click the ellipsis button in the Project Start Code property to open the Project Start Code window. d. In the Project Start Code window, enter: LIBNAME MyLibrary ‘C:\Users\amalik\Documents\SAS Projects\MyLibrary’; e. Click Run Now. This will create the library MyLibrary and will save the files in C:\Users\amalik\Documents\SAS Projects\MyLibrary. 4. Select the Save Data node and adjust the following properties. i. In the Filename Prefix property, enter Cereal. ii. In the File Format property, ensure SAS (.sas7bdat) is selected. iii. Click the ellipsis button in the SAS Library Name property to open the Select a SAS Library window. Select MyLibrary and click OK. 5. Run the Save Data node. 6. In the operating system file browser, navigate to the C:\Users\amalik\Documents\SAS Projects\MyLibrary directory and verify that the SAS data set, cereal_train.sas7bdat was created. If you found this useful, don't forget to Subscribe, and Click Like - Thanks :-)

Видео How to Import Excel CSV files into SAS 2020 автора Бухгалтерия и контроль затрат в Excel
Страницу в закладки Мои закладки
Все заметки Новая заметка Страницу в заметки