Documentation Fixes (ADR example)

from https://app.cloudquant.com/#/glossary/376
the code snippet listed contains 2 errors.

@classmethod
def is_symbol_qualified(cls, symbol, md, service, account):
    GUID = '>6b2fc6d0-3f87-41c3-a8e2-1507f43cb36e'
    # This combination of service calls returns a 1 if the current symbol is in the specified list, a zero if it is not
    myList = service.symbol_list.in_list(service.symbol_list.get_handle(GUID),symbol)
    return mylist and md.stat.prev_close>2 and md.stat.prev_close<500 and md.stat.avol>100000

1) The leading '>' on the GUID is a typo. Omit the the '>'.

2) myList variable is mylist (lowercase l) on back to back lines. (global name 'mylist' is not defined). change mylist to myList.

Comments

Sign In or Register to comment.