Excel formula which returns the internal rate of return for a schedule of cash flows
Questions tagged [xirr]
44 questions
1
vote
1 answer
How do I create an XIRR function based on unique names and between certain dates?
I'm trying to create an XIRR function that will calculate the return based on an unique investment names and corresponding cash flows between certain dates. For example, I want to calculate the IRR for Investment A between 01/16/2018 to 5/20/2018…

Shawn
- 11
- 2
1
vote
1 answer
Improving loop performance with function call inside
library(plyr);
library(sqldf);
library(data.table)
library(stringi);
library(RODBC);
dbhandle <- odbcDriverConnect('driver={SQL Server};server=.;database=TEST_DB;trusted_connection=true')
res <- sqlQuery(dbhandle, 'Select Company_ID,
…

The Unculled Badger
- 760
- 4
- 18
1
vote
0 answers
how to do XIRR calculation in php?
I have used PHP class from, http://www.phpclasses.org/ but it gives -1571465320791500131898188521929991589462016.00 % this as answer many times(you can take this example, date1= 04/14/2015, date2=08/19/2015(mm/dd/yyyy format), value1=-110,value2=5)…

vikram
- 189
- 3
- 13
0
votes
0 answers
Why google sheets is not calculating the XIRR?
Sample Google Sheet
I am trying the XIRR formula on a very basic data but not sure why system is not calculating it.
I am using formula for individual cell =XIRR(I2,C2) and for total =XIRR(I2:I4,C2:C4). Please guide how can I correct or what wrong I…

ankitkja
- 3
- 2
0
votes
1 answer
Big Difference in XIRR vs IRR calculation
Background
I am getting substantially large variation in XIRR vs IRR calculations.
Problem & Help requested
Can someone please explain why I get two very different outcomes, and which method is more accurate? I've provided an example of cashflows…

Bobby Heyer
- 531
- 5
- 18
0
votes
0 answers
How to calculate xirr in a dataframe in Python with pyxirr (or numpy, or scipy or other) library using this same logic created in Excel?
I need to calculate the XIRR at the end of each month considering all inflows that occurred on previous dates, but considering a single outflow.
Logic in Excel:
syntax (Excel) xirr function
My dataframe:
data = ({'movement': ['inflow', 'outflow',…

Gabriel Garcias
- 1
- 1
0
votes
0 answers
Assistance with XIRR Formula
When using XIRR to calculate the performance of a stock trading account, do you need to have a beginning cash flow equal to the starting balance of the account (seed money) ?
When I do that, it throws the formula completely for a loop and I either…

madmoneymike5
- 41
- 5
0
votes
1 answer
Google Sheets: Convert Horizontal Transaction Data into Chronological Statement + Combining Columns of Data
On a sheet named, "Performance," I have data concerning stock trades in a row like so:
A B C D E F G H I J
1 TICKER TRADE OPEN DATE TRADE CLOSED…

madmoneymike5
- 41
- 5
0
votes
1 answer
Converting for() loops to apply() functions in R for a custom XIRR function
I've currently been looking for functions to calculate the XIRR of a large database of cashflows/balances in R, and I've come across this function, which I've been trying to modify to fit my code:
library(tidyverse)
xirr2 <- function(exflow, date)…

matogoro
- 15
- 5
0
votes
1 answer
How to loop over grouped data Payments and dates in Pyxirr library in XIRR function
I am trying to get XIRR for each customer with multiple entries with dates and payments in float.
I want to find XIRR for each customer by grouping them with Unique ID
Code I am trying
import pandas as pd
from pyxirr import xirr
result =…

Ajit
- 39
- 6
0
votes
1 answer
XIRR function in LibreOffice giving strange results
Version: 7.2.3.2 / LibreOffice Community
Build ID: 20(Build:2)
CPU threads: 8; OS: Linux 5.3;
UI render: default; VCL: kf5 (cairo+xcb)
Locale: en-GB (en_GB.UTF-8); UI: en-GB
Calc: threaded
http://www.zen224037.zen.co.uk/LibreOfficeBug.ods
The two…

Richard Parkins
- 347
- 2
- 13
0
votes
2 answers
Cycle through a list of Investors and calculate the XIRR for each one to automate process
So I have been stuck on this problem for a few days. I have looked at some others codes but I am still coming up short. I am not the best at VBA either.
I have a list of investors with their attached payments and dates. I am trying to run a command…

RepCom1142
- 11
- 1
0
votes
1 answer
XIRR function in pivot table
I'm trying to add XIRR formula to pivot table but either I'm doing something wrong, either it's impossible.
Here on the picture is sample data, formula I've put and XIRR calculated in single cell with the same data (so It works outside pivot table)

graffit
- 1
- 1
0
votes
2 answers
Excel XIRR Function returning invalid calculation
When running the XIRR function "=XIRR(G163:G168,F163:F168)" where the cashflow is in G163:G168 and my dates are in F163:F168, excel is returning a value of .000000298023% which is definitely not correct. Any advise would be greatly…
user5552631
0
votes
1 answer
Can someone see what is wrong with this XIRR() computation in Google Sheets? (I have sent a request to Google ...)
Please review https://docs.google.com/spreadsheets/d/1cWIAdWylD5Mx8zP5gFwkSVkAYLwXuFopoH_9mi2tGWg/edit#gid=0. It contains some dates and corresponding investment amounts. My goal is to have XIRR() compute the rate of return. While it is obvious that…

krbabu
- 51
- 1
- 5