Learn R Programming

rusquant (version 1.1.4)

getPortfolio: Retrieve portfolio data from different brokers/exchanges

Description

This function retrieves portfolio data from different brokers/exchanges such as Tinkoff, Finam and Alor.

Usage

getPortfolio(
  src = "",
  board = "MOEX",
  api.key = "",
  clientId = "",
  verbose = TRUE
)

Value

A list of portfolio data containing the positions and other relevant information

Arguments

src

character indicating the name of the broker/exchange (options are 'tinkoff', 'finam', or 'alor')

board

character indicating the name of the board (only required for Alor, default is 'MOEX')

api.key

character representing the authorization key required for accessing broker/exchange API

clientId

character representing the ID of the client whose portfolio data is being retrieved

verbose

logical value indicating whether to print verbose output (default is TRUE)

Author

Vyacheslav Arbuzov

Examples

Run this code
# Retrieve portfolio data from Tinkoff
getPortfolio(src = 'tinkoff', api.key = 'my_api_key', clientId = 'my_client_id')

# Retrieve portfolio data from Finam
getPortfolio(src = 'finam', api.key = 'my_api_key', clientId = 'my_client_id')

# Retrieve portfolio data from Alor
getPortfolio(src = 'alor', api.key = 'my_api_key', clientId = 'my_client_id', board = 'MOEX')

Run the code above in your browser using DataLab