Creating charts from data > Example: Charting delimited data
 

Example: Charting delimited data

FileMaker Pro Advanced can chart multiple data entries from a single field when each data value in the field is separated by a carriage-return character (carriage return-delimited data).

About the chart

In this example, you create a new file containing two return-delimited fields: Country and Customer Count. The fields are located on one layout and all data is stored in one record. Then you create a column chart that compares the number of customers located in each country.

Create a file

1. Choose File menu > Create New, then double-click Blank.

2. Name the file Worldwide Customers, then click Save to save the file on your hard disk.

The file opens in Browse mode. If the Manage Database dialog box displayed, click OK. The first table and layout are created for you. Both have the same name as the file.

Define and format the fields

1. Choose View menu > Layout Mode.

2. In the Fields tab, click New field button to add a new field, then type Country.

3. Create another field, named Customer Count.

4. On the layout, select the Customer Count field and field label, and drag them down about an inch.

5. Select the Country field and drag its bottom handle down until you see five rows in the field.

6. Select the Customer Count field and drag its bottom handle down until you see five rows in the field.

7. Choose Layouts menu > Save Layout, then click Exit Layout to save the changes and return to Browse mode.

Tip  You can select Save layout changes automatically (do not ask) if you want the layout changes saved when you exit.

Add data to the file

1. Click New Record in the status toolbar.

2. In the Country field, type the following, pressing Enter or Return after each country name.

Spain
Italy
Japan
Germany
USA

3. In the Customer Count field, type the following, pressing Enter or Return after each value.

15
6
23
10
29

You have created two fields that contain return-delimited data.

Create a column to compare the number of customers in each country

1. Click Edit Layout in the layout bar to switch to Layout mode.

2. Drag the gray body part boundary down to make room for the chart.

3. Click the Chart tool Chart tool in the status toolbar, then click in the body layout part and drag a large rectangle where you want the chart to appear.

The Chart Setup dialog box appears.

4. In the Chart inspector, click Data Source and choose Current Record (delimited data).

5. In the Chart area of the Chart inspector, enter the following:

 

For

Do this

Title

Type Customers by Country.

Type

Choose Column.

X-Axis (Horizontal)

For Title, type Countries.

For Data, click Specify button, choose Specify Field Name, choose Country in the list, then click OK.

Data values from the Country field appear below the chart. They will be labels for the columns in your chart (x-series). This is the data you are comparing.

Y-Axis (Vertical)

For Title, type Number of Customers.

For Data, click Specify button, choose Specify Field Name, choose Customer Count in the list, then click OK.

The columns in your chart show the data values from the Customer Count field (y-series). This is the data you are measuring.

6. Click Done.

7. Choose Layouts menu > Save Layout, then click Exit Layout to save the changes and return to Browse mode.

Each return-delimited value in the Country field corresponds to a return-delimited value in the Member Count field in the order the data was entered.