Welcome, Guest
You have to register before you can post on our site.

Username/Email:
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 896
» Latest member: cacuocgame188
» Forum threads: 45
» Forum posts: 114

Full Statistics

Online Users
There are currently 15 online users.
» 1 Member(s) | 14 Guest(s)
xvladax007

Latest Threads
Troubleshooting and Known...
Forum: Bugs and Problems
Last Post: admin
07-25-2021, 04:13 PM
» Replies: 4
» Views: 2,291
Closing a system
Forum: General Discussion
Last Post: admin
07-24-2021, 12:23 PM
» Replies: 1
» Views: 33
Support allocation method...
Forum: General Discussion
Last Post: Marcel
07-15-2021, 06:46 AM
» Replies: 2
» Views: 1,058
Delayed Signals
Forum: Documentation
Last Post: admin
06-17-2021, 03:01 PM
» Replies: 0
» Views: 311
tracking individual strat...
Forum: Feature Requests
Last Post: ivanf
06-09-2021, 09:47 PM
» Replies: 8
» Views: 2,040
Get last used Trade ID fr...
Forum: Feature Requests
Last Post: patelgopesh
06-01-2021, 06:46 AM
» Replies: 2
» Views: 202
Tips and Tricks (Miscella...
Forum: Documentation
Last Post: admin
05-25-2021, 11:03 AM
» Replies: 0
» Views: 230
Strategies
Forum: Documentation
Last Post: admin
05-21-2021, 09:34 AM
» Replies: 2
» Views: 1,961
Custom Stop and Target Or...
Forum: Documentation
Last Post: admin
05-12-2021, 03:00 PM
» Replies: 0
» Views: 248
Features Roadmap
Forum: Feature Requests
Last Post: EbertM
04-28-2021, 07:00 AM
» Replies: 2
» Views: 686

 
  F.A.Q.
Posted by: admin - 11-06-2018, 02:28 PM - Forum: General Discussion - No Replies

Frequently Asked Questions
This thread will contain a list of frequently asked questions that will help users get an understanding of the Alera Portfolio Manager (APM).
Feel free to post other questions you have or think should be added to this list in the comments.

Where do I download the software from?
You can download APM from the installation page.

What Brokers does APM work with?
Currently, the software is only compatible with Interactive Brokers (IB), but we plan to add more brokers in the future.
You will have to open an account with IB in order to use the software.

How do I test APM before using it with real money?
When you open an account with IB, you are given a free paper trading (simulated trading) account that you can use to test APM.

Does it cost money?
The software is free to use for 3 months with a paper trading account (no sign-up required currently).
If you would like to use it with a real account, please email us at contact@aleratrading.com.

What do you do with my account information?
We understand that traders want to keep not only their strategies private, but also their account information. 
That is why we designed APM so that no information, other than your account ID (for licensing purposes), is sent to our servers.

What can I trade with APM?
APM currently handles only U.S. stocks. We plan to support options, futures, forex, and crypto.

Print this item

  Stock Screeners
Posted by: admin - 11-04-2018, 07:21 PM - Forum: Documentation - Replies (4)

Stock Screeners
Stock screeners provide a different approach to handling your portfolio. The idea is that you want to evaluate stocks based on certain criteria (ranking) and only hold X stocks in your portfolio based on their rank. To create a stock screener, simply select the File Screener, the Google Drive Screener or the Finviz Screener.

Note that the stock screener only places Market, Market on Close or Market on Open orders, so be aware of the potential issues with such orders. It is possible to prevent some of the issues with the Protect Market Orders field, which is explained in the Strategies Guide.

Number of Stocks
The Number of Stocks field allows you to select how many positions you would like to hold in your portfolio. APM will always try to maintain this number of stocks by taking in consideration the current positions, the sell orders and then filling the open spots. However, if the Number of Stocks is decreased, then APM will not automatically sell stocks at random, it will instead wait for them fall out of the screener (as per the selection mode below).

Selection Mode
The Selection Mode allows you to specify how you would like to process the screener.

Keep Only First

  • This mode will only hold only the first X stocks in the screener and sell the rest (X is number of stocks you specified in the Number of Stocks field) 
Prioritize First
  • This mode will prioritize the top stocks in the screener. It will only sell stocks if they fall completely out of the screener, rather than out of the top X stocks like the Keep Only First mode.
Dual Screener
  • This mode allows users to provide a different set of criteria for entering and exiting positions (e.g. enter on an oversold condition and exit on overbought)  
  • A stock will only be sold if the screener explicitly states it
Creating a Screener File

Similar to regular signal files, a screener file must end have one of the supported extensions (.sig, .sig.txt, .sig.csv) and be placed in the folder specified at the bottom right of the APM.
A screener signal in a .sig.txt file must have the following format:

[BUY/SELL] [Ticker]

An example screener file for the modes Keep Only First and Prioritize First would be:

BUY AAPL
BUY SPY
BUY IBM
BUY AA

An example screener file for the Dual Screener mode would be:

BUY APPL
BUY SPY
SELL IBM
SELL AA

Note that SELL actions will be ignored unless the Dual Screener mode is being used.

Web Screeners
Currently, users can create screeners using finviz and process the stocks in that screener with the same modes as the file screener.
Simply copy the URL for the screener you would like to use into the Buy URL field (and the Sell URL field for the Dual Screener).

Print this item

  Stock Signals
Posted by: admin - 09-11-2018, 07:03 PM - Forum: Documentation - Replies (8)

What are Signals?
Signals are used to create orders in the market and are sent by what we call Signal Providers (SPs). There are various types of signals that are tailored for specific purposes in order to allow customization of signals and prevent errors on the side of the SP and the user. This guide presents all the types of signals, how they are processed, and how to create them.

Further reading: Conditional Signals and Delayed Signals

Actions
The action specifies the purpose of the order and ensures that the current position can be properly changed by the order. Note that if the signal is not ignored as result of the action (see below for when a signal is ignored), then the signal will replace any existing order.

Buy To Open (BTO)

  • Signal to open a long position (i.e positive number of shares)
  • If the current position is not neutral, this signal will be ignored
Sell To Open (STO)
  • Signal to open a short position (i.e negative number of shares)
  • If the current position is not neutral, this signal will be ignored
Close (CLOSE)
  • Signal to close a position, regardless of whether it is short or long
  • If the current position is neutral, it will cancel any existing orders
Sell To Close (STC)
  • Signal to close a long position
  • If the current position is not long, this signal will be ignored
Buy To Close (BTC)
  • Signal to close a short position
  • If the current position is not short, this signal will be ignored
Long  (LONG)
  • Signal to make the current position long
  • This will work even if the current position is short
Short (SHORT)
  • Signal to make the current position short
  • This will work even if the current position is long
Add to Long (ATL)
  • Signal to increase the current long position
  • If the current position is not long, this signal will be ignored
  • Requires a signal ID to be processed
Add to Short (ATS)
  • Signal to increase the current short position (i.e. go more short)
  • If the current position is not short, this signal will be ignored
  • Requires a signal ID to be processed
Subtract from Long (SFL)
  • Signal to decrease the current long position
  • If the current position is not long, this signal will be ignored
  • Requires a signal ID to be processed
Subtract from Short (SFS)
  • Signal to decrease the current short position (i.e. go less short)
  • If the current position is not short, this signal will be ignored
  • Requires a signal ID to be processed
Quantity and Units
The quantity is used to specify how much of a stock is bought. When a quantity is specified, the unit must also be specified.

Shares (SHARES)
  • Specifies the number of shares to buy
Dollars ($)
  • Specifies the total dollar value to be bought
Percent Portfolio (%PORTFOLIO)
  • Specifies that the total dollar value bought should be a percent of the portfolio/strategy allocation
Percent Position (%POSITION)
  • Specifies that the total dollar value bought should be a percent of the current position (this means if the current position is neutral, then the signal is ignored)
Percent Cash (%CASH)
  • Specifies that the total dollar value bought should be a percent of the current cash available to the strategy
  • Available cash is calculated as: strategy allocation - total exposure, where total exposure = (long exposure + short exposure)
  • Note that whatever asset you are purchasing will not be included in the total exposure calculation
  • For example, if strategy allocation is $10,000 and you are long $1,000 of AAPL, short $500 of IBM, and long $500 of SPY, then the signal
    LONG SPY 50 %CASH
    would see that total exposure is $1,500 (AAPL and IBM), so available cash is $10,000-$1,500 = $8,500. Therefore, we want to hold $8,500/2 = $4,250 of SPY, which means we need to BUY $3750 of SPY (since we already have $500)
  • This unit type may be confusing to understand at first, but it will make more sense as you read the rest of the documentation.
Percent Account Cash (%ACCTCASH)
  • Specifies that the total dollar value bought should be a percent of the current cash available to ALL your strategies
  • Available cash is calculated as: total allocation among all strategies - total account exposure, where total exposure = (long exposure + short exposure)
  • Note that whatever asset you are purchasing will not be included in the total exposure calculation
  • For example, if Strategy1 and Strategy2 each have allocation $10,000, and you are long $1,000 of AAPL, short $500 of IBM, and long $500 of SPY, then the signal
    LONG SPY 50 %ACCTCASH
    would see that total exposure is $1,500 (AAPL and IBM), so available cash is 2x$10,000-$1,500 = $18,500. Therefore, we want to hold $18,500/2 = $9,250 of SPY, which means we need to BUY $8750 of SPY (since we already have $500)
Custom Lots (LOTS)
  • Specifies that the unit to be used is whatever the user specified in the Custom Lot Size field in the strategy window.
  • Note that the Custom Lot Size field is limited to the Shares and Dollars as units.
Order Type
The order type is used to specify what kind of order is used to enter the market.
Note that some order types (such as MOO) might be automatically cancelled in PAPER trading accounts on Interactive Brokers, but will work correctly in LIVE accounts. You may want to use MKT orders for paper trading and then switch to MOO on your live account if you're having issues.

Market (MKT)
  • An order which will be executed at the current market price
Market on Close (MOC)
  • A market order that will be placed when the market closes
  • Note that these orders must be placed before 3:45pm EST, so your strategies must run before then
  • The advantage of these kinds of orders is that there is no spread (difference between bid and ask price) when the market closes
Market on Open (MOO)
  • A market order that will be placed when the market opens
  • Similar to MOC orders
  • Note that in Interactive Brokers these orders will appear as MKT orders with a Time in Force of OPG
Limit (LMT)
Limit on Close (LOC)
  • A limit order that will be placed when the market closes
  • Similar to the Market on Close order, this type of order must be placed before 3:45PM EST on most US exchanges
Limit on Open (LOO)
  • A limit order that will be placed when the market open
  • Similar to the Market on Open order, this type of order must be placed before 9:28AM EST on most US exchanges
Stop Market (STPMKT)
Stop Limit (STPLMT)
Limit If Touched (LIT)
Time in Force
The time in force specifies how long an order will stay in the market.

Day (DAY) - Day orders stay in the market until it closes. If they are not executed, then they are automatically removed.
Good 'Til Cancelled (GTC) - GTC orders stay in the market until they are executed or cancelled.
Good 'Til Date (GTD) - GTD orders stay in the market until the specified time. Format should be YYYYMMdd hh:mm:ss zzz where zzz is the timezone e.g. 20200108 15:30:00 EST
*NOTE* In order to get London time, you should use GMT as the timezone. In APM we include daylight savings time in GMT in order to give users a way to specify London time. If you don't want the adjusted time, you should use UTC as the timezone.

It is recommended to use DAY or GTD orders because there is no fee if they are not executed and automatically cancelled (whereas there is a cancellation fee for GTC orders).

Signal ID
A signal ID is a positive integer that allows APM to identify duplicate orders and prevent them from causing potential issues. Most of the actions do not have issues with placing duplicate orders, so signal IDs are not required (although they are allowed) for these actions. However, some of the actions, namely ATL, SFL, ATS, and SFS, do not naturally prevent duplicate orders, so they require signal IDs.

The first signal ID can begin at 1 (not 0), and every ID after must be greater than the last. To reset signal IDs back to 1, the signal ID must be smaller than the last signal ID by at least 10000 (this will ignore the normal rule for signal IDs). The order with this smaller ID will be processed as if it had no ID, and the next valid ID will be 1. A tip for simplifying this process is that when you want to reset the IDs and you know the last ID is at least 10001, then you can place orders beginning with ID 1 again instead of trying to reset the ID then starting at ID 1.

Note that when no signal ID is specified, orders with the actions BTO, STO, CLOSE, STC, BTC, LONG, and SHORT will be placed even if other signals do have IDs.

Signal Structure
Signals must follow the format below in order for them to be processed correctly:

[Action] [Ticker] [Quantity Units] [Type Price] [Time in Force] [ID]

The Action is one of BTO, STO, CLOSE, STC, BTC, LONG, SHORT, ATL, ATS, SFL, SFS
The Ticker must be of a valid US stock, for example AAPL.
The Quantity must be a positive real number followed by one of the Units: $, SHARES, %PORTFOLIO, %POSITION, LOTS
The Type is one of MKT, MOC, MOO, LMT, LOC, LOO, STPLMT. The types LOC, LOO, LMT must be followed by a price. And STPLMT must be followed by two prices (the stop and limit)
The Time in Force is one of GTC and DAY.
The ID is of the form 'ID <number>' and specifies the signal ID.

Here are some example signals:

BTO AAPL
STO AAPL 100 SHARES DAY
LONG AAPL 1000 $
CLOSE AAPL
CLOSE AAPL LMT 230 GTC
LONG AAPL 10 %PORTFOLIO MKT
ATL AAPL 50 %POSITION LMT 200 DAY ID 20
ATL AAPL ID 30
LONG AAPL STPLMT 400 401 DAY
LONG AAPL LIT 200 195 DAY
LONG AAPL LMT 200 GTD 20200108 15:30:00 EST

The only mandatory fields are the Action and Ticker.
If the Quantity and Units are not specified, the system will use the user defined Custom Lot Size to determine the number of shares to trade.
This happens in the signals BTO AAPL and ATL AAPL ID 30.

Creating and Processing Signals

File
A file with one signal per line can be processed by the 'Local File' Signal Provider. This file must end with a valid extension (.sig .sig.txt .sig.csv) and placed in the folder specified by the path on the status bar at the bottom of the APM window. Note that this folder is not created until the strategy is saved for the first time (i.e. it is not a 'new' strategy).
Set the Max Number of Positions field to limit the number of positions your strategy will take from the signal provider. If you do not need this field, then set it to a large value like 1000.

Try to run Order Preview to make sure that the signals are processed correctly. You can view any errors in the log tab if some signals are not processed as expected.
Note that once you run your strategy for real, the signal will be moved to the ProcessedSignals folder (which is also located at the path on the status bar).
This means you wont be able to run your strategy again because there won't be any signal files left to process (running Order Preview won't move your signal files).

Other Signal Types
Signals can also be created from stock screeners or be pulled from online.

Print this item