By the end of this chapter you will be able to:
- Collect data from a spreadsheet
A file containing a mapping of Counties to Regions can be found in the input files, at:
…\inputData\AddressCheck\regionsByCounty\regionsByCounty.xlsx
You will use this data to find the Region for each of the customer addresses that you have already loaded. Notice that there is a header line in this file with the column names of the data.
Add You will now add a new file collector to read this file into the new model you created in exercise 1: Introduction to Modelling analysis model:
- Hover your mouse over s in the toolbar to show the list of options.
- Drag
Insert excerpt |
---|
| _file_collector |
---|
| _file_collector |
---|
nopanel | true |
---|
|
onto the model. - In the new file collector form that pops up New FileCollector settings on the right of your screen, enter the Name:
Regions by County.
- Press
Insert excerpt |
---|
| _finish |
---|
| _finish |
---|
nopanel | true |
---|
|
. - You will now see the new new Regions by County file collector in the model.Save
- Press
Insert excerpt |
---|
| _save_saveModel |
---|
| _save_saveModel |
---|
nopanel | true |
---|
|
in the toolbar to save the model.
Set up File Collector and table
- Hover over your new Regions by County
Insert excerpt |
---|
| _file_collector |
---|
| _file_collector |
---|
nopanel | true |
---|
|
, and press Insert excerpt |
---|
| _upload_file |
---|
| _upload_file |
---|
nopanel | true |
---|
|
- In the file explorer, go to: …\inputData\AddressCheck\regionsByCounty
- Select the file regionsByCounty.xlsx and press Open.
- In the Upload Managed File form box, press Upload File.
You will see a table appear on your model – PhixFlow has automatically configured the file collector and the table to load the file into PhixFlow.
Pause file data
To pause the data loaded from the file:
- Hover over the table RegionsByCountyyour new table Regions By County.
- In the hover menu press
Insert excerpt |
---|
| _static |
---|
| _static |
---|
nopanel | true |
---|
|
. - Press
Insert excerpt |
---|
| _finish |
---|
| _finish |
---|
nopanel | true |
---|
|
in the table settings.
Further information on pausing files can be found on 2 Reading data from files into PhixFlow.
Run Analysis and view table data
- Hover over your new table, and press
Insert excerpt |
---|
| _run_analysis |
---|
| _run_analysis |
---|
nopanel | true |
---|
|
in the hover menu. - Wait for your task to complete.
- View Then view the data : hover by hovering over the Regions By County table and in the hover menu press pressing
Insert excerpt |
---|
| _view_show |
---|
| _view_show |
---|
nopanel | true |
---|
|
. - In the drop down list, select Default View.The data will show like the image below:
- Image Added
- In the model window, click
Insert excerpt |
---|
| _save_saveModel |
---|
| _save_saveModel |
---|
nopanel | true |
---|
|
.