ECE Student Success Toolkit - Free CCDF Charts

Blog Post created by BradJolly Employee on Sep 19, 2018

There is an obvious, longstanding trend in electrical and computer engineering (ECE) toward energy conservation and ever-longer battery life. This is especially true in applications related to the Internet of Things (IoT), where expectations of 5- and 10-year battery life for sensors are common. It is also true for battery-powered medical devices located with the human body, where changing a battery can be both expensive and risky.


One common tool for displaying how charge is consumed from a battery is the complementary cumulative distribution function (CCDF) chart, shown below.


Figure 1: CCDF Chart


We can see at a glance that the device under test (DUT) spends nearly all of its time at current levels above 1 µA, but less than 10% of its time at current levels above 10 µA. The other way to think about that is to say that the device spends about 90% of its time in at single-digit µA levels of current.


Many Keysight instruments, including the N6705, the X8712A, and the CX3300 Series can produce CCDF charts, but students often need to produce a CCDF chart when they either lack the necessary equipment or when the equipment is across campus, an inconvenient distance away. Fortunately, the student with good spreadsheet skills can create a CCDF chart in just a few minutes by following the procedure below.


Step 1: Load the data into the spreadsheet

Put the current reading data in column B, and number the rows in column A, as shown. The row numbers allow you to return the data to its original order after we sort it. In this case, we have 48,000 rows of data.


Figure 2: Data loaded into the spreadsheet and numbered


Step 2: Sort the data by value, number, and prepare to eliminate data

Sort the data in ascending order by current level. Then insert a new column A, and number the rows from 1 to 48,000. Finally, put the following formula into cell D2: =mod(a2,20). Then copy it down to the bottom of the data. This formula will count from 1 to 19, return to 0, and then count up to 19 again. This pattern repeats to the end. We do this because most spreadsheet software has difficulty graphing huge data sets, so we are going to select only every twentieth value.


Figure 3: Data sorted by ascending current levels.


Step 3: Bring every twentieth value to the top of the list

Sort the data by the Select and Sorted columns. As you can see in column A below, this brings every twentieth value to the top of the list for easy graphing.


Figure 4: Every twentieth value at the top of the list


Step 4: Change column D to represent portion of time remaining.

In cell D2, change the formula to: =1-A2/48000. This will indicate the portion of measurements remaining as a number decreasing from 1 to 0. Copy the formula down until it hits 0, which will be in row 2401.


Figure 5: Count portion of measurements remaining down from 1 to 0.


Step 5: Replace the values in column C with their base 10 logarithms

Given the highly dynamic nature of current in many IoT devices (sleep in nA or µA and operation in mA), it usually makes sense to replace the data in column C with their base 10 logarithms. In cell E2, type =log10(C2) and copy this formula down to row 2401. Then copy and paste the values from column E over those in column C.


Figure 6: Values in column C replaced with their base 10 logarithms


Step 6: Create an X-Y line graph out of columns C and D

At this point, you are ready to create the CCDF chart. Use the X-Y (scatter) plot feature on the range C2:D2401to create the graph shown below.


Figure 7: Basic CCDF chart created from 2400 rows of columns C and D.


Step 7: Label the graph and format the axes

Even though the graph in Figure 7 is correct, it is generally worth taking a minute or two to improve its appearance. Edit the axes and the various labels to improve the readability of the chart, as shown below. You may also want to turn on the grid lines, but remember not to be misled by the logarithmic nature of the X-axis.


Figure 8: CCDF chart with better labeling for improved readability



The CCDF chart is very useful in summarizing how frequently a device under test spends its time at various current levels. By following the simple procedure outlined above, you can create a CCDF of current data by using nothing more than commonly available spreadsheet software.