Hello,
Can you please help me amend my code based on the following questions:
- How can I create a scatter plot showing Gross margin on x-axis and EBITDA margin on y-axis?
2. How can I create a BUBBLE chart showing the same data in #1 above, where the bubble is defined by market cap in USD?
Thank you
-----------------------------------------------
ric = 'AAPL.O'
df, err = ek.get_data([ric,"Peers("+ric+")"],
['TR.CompanyMarketCap',
'TR.RevenueMean',
'TR.GrossIncomeMean',
'TR.EBITDAMean'],
parameters = {
'Scale': '6',
'Curn': 'USD'
})
df
df.columns = ['RIC', 'Market Cap', 'Revenue', 'Gross Income', 'EBITDA']
df['Gross Profit Margin'] = df['Gross Income']/df['Revenue']
df['EBITDA Margin'] = df['EBITDA']/df['Revenue']
display(df)