The YEARFRAC function in Excel returns a decimal value that represents fractional years between two specified dates.

Syntax:

=YEARFRAC(start_date, end_date, [basis]) 

Arguments:

  • start_date – The start date.
  • end_date – The end date.
  • basis – [optional] The type of day count basis to use (see image below).

YEARFRAC Function Example

As mentioned above, Excel calculates a decimal number that represents the fraction of a year between two dates. Excel also uses whole days when calculating the fractional data. Let’s look at the example below. Pay attention to how the optional argument changes the result.

Leave a Reply

What is Tableau?

Learning Tableau for Data Visualization Tableau is a data visualization tool used in business and academics. This software allows you

Read More »

Randomly Sort Data in Excel

Learn to randomly sort data in Excel by using this simple trick. The RAND Function can be used to randomly sort a data set by applying a numerical number.

Read More »
Scroll to Top