[Quantproject-developers] QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRo
Brought to you by:
glauco_1
|
From: <gla...@us...> - 2003-11-09 19:46:41
|
Update of /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows
In directory sc8-pr-cvs1:/tmp/cvs-serv13476/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows
Added Files:
TotalNumberOfTrades.cs
Log Message:
Computes the total number of trades for the
account report summary object
--- NEW FILE: TotalNumberOfTrades.cs ---
using System;
using System.Data;
using QuantProject.Business.Financial.Accounting.Reporting.Tables;
namespace QuantProject.Business.Financial.Accounting.Reporting.SummaryRows
{
/// <summary>
/// Summary description for TotalNumberOfTrades.
/// </summary>
public class TotalNumberOfTrades : SummaryRow
{
public TotalNumberOfTrades( Summary summary )
{
double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl );
this.rowDescription = "Total # of trades";
DataRow[] DataRows =
summary.AccountReport.RoundTrades.DataTable.Select( "(ExitPrice is not null)" );
this.rowValue = DataRows.Length;
}
}
}
|