Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Custom Factor syntax error

Why am I getting the syntax error shown below when trying to make a custom factor?

  File "<ipython-input-25-68ab1ef0f663>", line 2  
    Class factor(CustomFactor){  
               ^  
SyntaxError: invalid syntax  

Edit: Never mind I'm stupid

1 response

The issue is that you're not using proper Python syntax. Class should be lowercase and you need to use colons and whitespace to organize your code rather than curly braces.