[Quantproject-developers] QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryR
Brought to you by:
glauco_1
Update of /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv12665/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows Modified Files: AverageLongTradePercentageReturn.cs AverageShortTradePercentageReturn.cs AverageTradePercentageReturn.cs LargestLosingTradePercentage.cs LargestWinningTradePercentage.cs NumberWinningLongTrades.cs NumberWinningShortTrades.cs NumberWinningTrades.cs TotalNumberOfLongTrades.cs TotalNumberOfShortTrades.cs TotalNumberOfTrades.cs Log Message: - the code has been cleaned up to avoid warnings - standard indentation has been applied Index: AverageLongTradePercentageReturn.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/AverageLongTradePercentageReturn.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** AverageLongTradePercentageReturn.cs 19 Jun 2005 14:55:09 -0000 1.4 --- AverageLongTradePercentageReturn.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class AverageLongTradePercentageReturn : PercentageSummaryRow { public AverageLongTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average long trade % Return"; double avgReturn = 0.0; try --- 11,19 ---- /// </summary> [Serializable] ! public class AverageLongTradePercentageReturn : PercentageSummaryRow { public AverageLongTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average long trade % Return"; double avgReturn = 0.0; try *************** *** 24,31 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! this.rowValue = avgReturn; ! } } } --- 24,31 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! this.rowValue = avgReturn; ! } } } Index: NumberWinningShortTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/NumberWinningShortTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** NumberWinningShortTrades.cs 19 Jun 2005 14:47:40 -0000 1.4 --- NumberWinningShortTrades.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class NumberWinningShortTrades : IntegerSummaryRow { public NumberWinningShortTrades( Summary summary ) { ! this.rowDescription = "Number winning short trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try --- 11,19 ---- /// </summary> [Serializable] ! public class NumberWinningShortTrades : IntegerSummaryRow { public NumberWinningShortTrades( Summary summary ) { ! this.rowDescription = "Number winning short trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try *************** *** 25,31 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 25,31 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: AverageShortTradePercentageReturn.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/AverageShortTradePercentageReturn.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** AverageShortTradePercentageReturn.cs 19 Jun 2005 14:55:09 -0000 1.4 --- AverageShortTradePercentageReturn.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class AverageShortTradePercentageReturn : PercentageSummaryRow { public AverageShortTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average short trade % Return"; double avgReturn = 0.0; try --- 11,19 ---- /// </summary> [Serializable] ! public class AverageShortTradePercentageReturn : PercentageSummaryRow { public AverageShortTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average short trade % Return"; double avgReturn = 0.0; try *************** *** 21,32 **** avgReturn = (double) summary.AccountReport.RoundTrades.DataTable.Compute( ! "avg([%Profit])" , "(Trade='Short')" ); } catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! this.rowValue = avgReturn; ! } } } --- 21,32 ---- avgReturn = (double) summary.AccountReport.RoundTrades.DataTable.Compute( ! "avg([%Profit])" , "(Trade='Short')" ); } catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! this.rowValue = avgReturn; ! } } } Index: NumberWinningTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/NumberWinningTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** NumberWinningTrades.cs 19 Jun 2005 14:47:40 -0000 1.4 --- NumberWinningTrades.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class NumberWinningTrades : IntegerSummaryRow { public NumberWinningTrades( Summary summary ) { ! this.rowDescription = "Number winning trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try --- 11,19 ---- /// </summary> [Serializable] ! public class NumberWinningTrades : IntegerSummaryRow { public NumberWinningTrades( Summary summary ) { ! this.rowDescription = "Number winning trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try *************** *** 24,30 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 24,30 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: TotalNumberOfShortTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/TotalNumberOfShortTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** TotalNumberOfShortTrades.cs 19 Jun 2005 14:42:23 -0000 1.4 --- TotalNumberOfShortTrades.cs 18 Aug 2008 21:13:16 -0000 1.5 *************** *** 11,20 **** /// </summary> [Serializable] ! public class TotalNumberOfShortTrades : IntegerSummaryRow { public TotalNumberOfShortTrades( Summary summary ) { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of short trades"; try { --- 11,20 ---- /// </summary> [Serializable] ! public class TotalNumberOfShortTrades : IntegerSummaryRow { public TotalNumberOfShortTrades( Summary summary ) { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of short trades"; try { *************** *** 25,31 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 25,31 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: NumberWinningLongTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/NumberWinningLongTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** NumberWinningLongTrades.cs 19 Jun 2005 14:47:40 -0000 1.4 --- NumberWinningLongTrades.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class NumberWinningLongTrades : IntegerSummaryRow { public NumberWinningLongTrades( Summary summary ) { ! this.rowDescription = "Number winning long trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try --- 11,19 ---- /// </summary> [Serializable] ! public class NumberWinningLongTrades : IntegerSummaryRow { public NumberWinningLongTrades( Summary summary ) { ! this.rowDescription = "Number winning long trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try *************** *** 24,30 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 24,30 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: TotalNumberOfTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/TotalNumberOfTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** TotalNumberOfTrades.cs 19 Jun 2005 14:42:23 -0000 1.4 --- TotalNumberOfTrades.cs 18 Aug 2008 21:13:16 -0000 1.5 *************** *** 11,20 **** /// </summary> [Serializable] ! public class TotalNumberOfTrades : IntegerSummaryRow { public TotalNumberOfTrades( Summary summary ) { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try --- 11,20 ---- /// </summary> [Serializable] ! public class TotalNumberOfTrades : IntegerSummaryRow { public TotalNumberOfTrades( Summary summary ) { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of trades"; this.format = ConstantsProvider.FormatWithZeroDecimals; try *************** *** 26,32 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 26,32 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: LargestWinningTradePercentage.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/LargestWinningTradePercentage.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** LargestWinningTradePercentage.cs 19 Jun 2005 14:47:40 -0000 1.4 --- LargestWinningTradePercentage.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class LargestWinningTradePercentage : PercentageSummaryRow { public LargestWinningTradePercentage( Summary summary ) { ! this.rowDescription = "Largest winning trade"; try { --- 11,19 ---- /// </summary> [Serializable] ! public class LargestWinningTradePercentage : PercentageSummaryRow { public LargestWinningTradePercentage( Summary summary ) { ! this.rowDescription = "Largest winning trade"; try { *************** *** 23,29 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 23,29 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: TotalNumberOfLongTrades.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/TotalNumberOfLongTrades.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** TotalNumberOfLongTrades.cs 19 Jun 2005 14:42:23 -0000 1.4 --- TotalNumberOfLongTrades.cs 18 Aug 2008 21:13:16 -0000 1.5 *************** *** 11,20 **** /// </summary> [Serializable] ! public class TotalNumberOfLongTrades : IntegerSummaryRow { public TotalNumberOfLongTrades( Summary summary ) : base() { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of long trades"; try { --- 11,20 ---- /// </summary> [Serializable] ! public class TotalNumberOfLongTrades : IntegerSummaryRow { public TotalNumberOfLongTrades( Summary summary ) : base() { ! double totalROA = summary.TotalPnl / ( summary.FinalAccountValue - summary.TotalPnl ); ! this.rowDescription = "Total # of long trades"; try { *************** *** 25,31 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 25,31 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: AverageTradePercentageReturn.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/AverageTradePercentageReturn.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** AverageTradePercentageReturn.cs 19 Jun 2005 14:55:09 -0000 1.4 --- AverageTradePercentageReturn.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class AverageTradePercentageReturn : PercentageSummaryRow { public AverageTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average trade % Return"; try { --- 11,19 ---- /// </summary> [Serializable] ! public class AverageTradePercentageReturn : PercentageSummaryRow { public AverageTradePercentageReturn( Summary summary ) { ! this.rowDescription = "Average trade % Return"; try { *************** *** 22,28 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 22,28 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } Index: LargestLosingTradePercentage.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a2_Accounting/h5_Reporting/SummaryRows/LargestLosingTradePercentage.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** LargestLosingTradePercentage.cs 19 Jun 2005 14:47:40 -0000 1.4 --- LargestLosingTradePercentage.cs 18 Aug 2008 21:13:15 -0000 1.5 *************** *** 11,19 **** /// </summary> [Serializable] ! public class LargestLosingTradePercentage : PercentageSummaryRow { public LargestLosingTradePercentage( Summary summary ) { ! this.rowDescription = "Largest losing trade"; try { --- 11,19 ---- /// </summary> [Serializable] ! public class LargestLosingTradePercentage : PercentageSummaryRow { public LargestLosingTradePercentage( Summary summary ) { ! this.rowDescription = "Largest losing trade"; try { *************** *** 23,29 **** catch (Exception ex) { ! ex = ex; // to avoid compilation warning; } ! } } } --- 23,29 ---- catch (Exception ex) { ! string forBreakpoint = ex.Message; forBreakpoint = forBreakpoint + ""; } ! } } } |