Use the Excel LOOKUP Formula for Blood Glucose Categories in WPS Office
Question details
The user wants to automatically classify a blood glucose reading entered in a cell into categories such as Low, Normal, Borderline, High, or Dangerous using an Excel LOOKUP formula in WPS Office.

- Product
- WPS Office Spreadsheets
- Device & OS
- not provided
- Scenario
- The user maintains a blood glucose log or worksheet and needs a reusable formula that compares each reading with defined thresholds and returns the matching category.
- Observed behavior
- A glucose reading entered in B4 should display a category such as LOW, NORMAL, BORDERLINE, HIGH, or DANGEROUS in C4 without manually looking up a range.
Confirm the glucose thresholds in your worksheet and identify the cell that contains the reading, for example B4. Open the workbook in WPS Office Spreadsheets in editable mode and make sure the result cell is formatted as General or Text so the formula can display the category.
Use the LOOKUP Formula in WPS Office Spreadsheets to Classify Blood Glucose
Use this method when you have a glucose reading in one cell and want the adjacent cell to display the matching category automatically.
The LOOKUP function compares the reading to the lower boundary of each range. For the provided boundaries, values from 0 to below 4 return LOW, 4 to below 7.1 return NORMAL, 7.1 to below 10.1 return BORDERLINE, 10.1 to below 13.9 return HIGH, and 13.9 or above return DANGEROUS.
Always confirm the thresholds against a current clinical reference before relying on the formula for medical decisions.
Click cell C4 in your worksheet, next to the glucose reading that is entered in B4.
Type =LOOKUP(B4,{0,4,7.1,10.1,13.9},{"LOW","NORMAL","BORDERLINE","HIGH","DANGEROUS"}) in C4 and press Enter.
Select C4, drag the fill handle down through the remaining result cells, or press Ctrl+C and paste to the target cells.
Use WPS Spreadsheets to Classify Blood Glucose Categories with LOOKUP
Open WPS Office, create the LOOKUP formula in a Spreadsheets cell, and copy it down to label each glucose reading automatically using your defined threshold ranges.
- 1. Launch WPS Office Spreadsheets: Open WPS Office, click Spreadsheets, then open the workbook containing your glucose readings.
- 2. Click the result cell: Select C4 where the category should appear, next to the reading in B4.
- 3. Enter and fill the formula: Type =LOOKUP(B4,{0,4,7.1,10.1,13.9},{"LOW","NORMAL","BORDERLINE","HIGH","DANGEROUS"}) and press Enter, then use the fill handle to copy it to other result cells.
- 4. Check the returned category: Change the value in B4 to test each threshold and verify that C4 displays the expected category.

Frequently Asked Questions
Why does the LOOKUP formula return #N/A?
The LOOKUP formula can return #N/A when the lookup value is less than the first value in the array, such as a negative glucose reading, or when the cell contains text instead of a number. Make sure B4 contains a valid numeric reading and that the first threshold captures the lowest possible value.
Can I change the blood glucose thresholds in the formula?
Yes. Edit the first array {0,4,7.1,10.1,13.9} to use your own lower boundaries, and make sure the second array {"LOW","NORMAL","BORDERLINE","HIGH","DANGEROUS"} has the same number of items in the same order.
How do I copy the formula to other rows without breaking the reference?
Select the cell with the formula and use the fill handle in WPS Office Spreadsheets to drag it down, or copy and paste the cell. The B4 reference adjusts automatically to B5, B6, and so on unless you intentionally make it absolute.
Is LOOKUP better than using nested IF functions for blood glucose ranges?
For banded thresholds, LOOKUP is usually simpler and easier to read than a long nested IF formula. It matches the largest boundary that is less than or equal to the reading and returns the corresponding category from the result array.
Does this formula still work when the file is opened in Microsoft Excel?
Yes. Workbooks saved as .xlsx from WPS Office preserve the LOOKUP formula, and Microsoft Excel supports the same LOOKUP function with array constants.




