public BlmbrgF(WealthLab.Bars ds, string fieldID, string description) public static BlmbrgF Series(WealthLab.Bars ds, string fieldID) public static BlmbrgF Series(WealthLab.Bars ds, string dir, string fieldID) // added 2014.10.0.0
using System; using System.Drawing; using WealthLab; using WealthLab.DataProviders.Blmbrg;namespace WealthLab.Strategies { public class MyStrategy : WealthScript { protected override void Execute() { // Using the Series method DataSeries fund = BlmbrgF.Series(Bars, "PE_RATIO"); ChartPane fPane = CreatePane( 100, true, true ); PlotSeries(fPane, fund, Color.Blue, LineStyle.Solid, 2); // Using BlmbrgF constructor method BlmbrgF fund2 = new BlmbrgF(Bars, "NET_INCOME", "Net Income"); ChartPane fPane2 = CreatePane( 100, true, true ); PlotSeries(fPane2, fund2, Color.Green, LineStyle.Histogram, 2); } } }
using System; using System.Drawing; using WealthLab; using WealthLab.DataProviders.Blmbrg;namespace WealthLab.Strategies { public class MyStrategy : WealthScript { protected override void Execute() { ChartPane pePane = CreatePane( 100, true, true ); /* Tell BlmbrgF where the data is by first accessing a secondary symbol's data */ // Note: The call to BlmbrgF must occur 'immediately' after accessing the secondary Bars Bars msft = GetExternalSymbol("MSFT US", true); DataSeries pe = BlmbrgF.Series(msft, "PE_RATIO"); PlotSeries(pePane, pe, Color.Blue, LineStyle.Solid, 2); // Or with SetContext SetContext("MRK US", true); DataSeries pe2 = BlmbrgF.Series(Bars, "PE_RATIO"); PlotSeries(pePane, pe2, Color.Red, LineStyle.Histogram, 2); RestoreContext(); } } }