How to Create a Date-Based Calculation Pattern Across Excel Columns
Question details
The user needs a formula to distribute a base amount across multiple periods based on matching dates. The pattern requires returning the base amount on the start date, a reduced value in the next period, dividing that reduced value over the following three periods, and returning zero thereafter.

- Product
- Excel / WPS Spreadsheet
- Device & OS
- not provided
- Scenario
- Creating an amortization or financial schedule that distributes calculated amounts progressively across specific date columns.
- Observed behavior
- The goal is to automatically calculate and spread the base value across the following column cells based on dynamic date matching, stopping the calculation once the specific pattern completes.
Ensure your column headers and row references are formatted as valid dates in chronological order, and consider adding a helper row for counting periods to significantly simplify the formula logic.
Create the Pattern Using LET, IF, and MATCH Functions
Use a helper counter row and the LET function to cleanly identify the calculation stage and distribute the values accurately across periods.
This approach relies on adding a 'counter row' above your date headers to easily reference the sequence of periods. The LET function simplifies the logic by storing the matched period, while nested IF functions determine which calculation stage to apply based on the difference between the current period and the starting period.
Insert a new row above your date columns (e.g., row 2) and number it sequentially (1, 2, 3...) above each date.
Click on the first target cell where the calculation should begin evaluating the dates (e.g., cell I6).
Type the formula: =LET(baseval,MATCH($C6,$I$1:$T$1),IF($C6=I$1,$H6,IF(I$2-baseval=1,$H6/4*(-3),IF(AND(I$2-baseval>1,I$2-baseval<5),($H6/4*(-3))/3,0))))
Drag the fill handle (the small square at the bottom-right of the cell) across your columns and down the rows to complete the pattern for all entries.

Use IF and EDATE for Simple Date Progression
An alternative formula utilizing EDATE to handle month-over-month calculation changes without needing a helper row.
Effortlessly Manage Complex Data Patterns with WPS Spreadsheet
WPS Spreadsheet fully supports advanced array functions like LET, SEQUENCE, and MATCH, allowing you to implement dynamic date-based calculations seamlessly. Its powerful calculation engine is highly compatible with standard spreadsheet formats.
- 1. Open your workbook: Launch WPS Spreadsheet and open your existing file containing the financial data.
- 2. Input the formula: Select the target cell and paste your LET or IF formula directly into the formula bar.
- 3. Apply across columns: Use the fill handle to drag the formula across the desired date columns and rows.

Frequently Asked Questions
Why does the LET function return a #NAME? error?
This typically happens if you are using an older version of spreadsheet software that does not support the LET function. Upgrading to the latest version of WPS Office or Microsoft 365 will resolve this issue.
How can I lock cell references when copying formulas across columns?
Use absolute or mixed referencing by adding a dollar sign ($). For example, $C6 locks column C but allows the row to change, while I$1 locks row 1 but allows the column to change as you drag.
Can I use dynamic arrays to generate this calculation pattern automatically?
Yes, modern spreadsheet formulas can utilize functions like SEQUENCE, EXPAND, and WRAPROWS to output the entire calculation grid in one go, instead of dragging the formula across cells individually.
Why are my dates not matching correctly in the formula?
Ensure that both your row dates and column headers are formatted as actual Date values rather than text. You can check this by changing the cell format to 'Number'—true dates will convert into serial numbers (e.g., 44000).




