endpoints/resting_tremor_endpoints.py
def compute_tremor_constancy(tremor_classification_predictions):
    '''
    Compute tremor constancy for a given set of tremor predictions.
    :param tremor_classification_predictions: Tremor predictions as determined by tremor classifier. Binary predictions (1 = tremor, 0 = no tremor)
    :return: Percentage of detected tremor
    '''
    return tremor_classification_predictions.count(1)/float(len(tremor_classification_predictions))*100.

    Compute tremor constancy for a given set of tremor predictions.
    :param tremor_classification_predictions: Tremor predictions as determined by tremor classifier. Binary predictions (1 = tremor, 0 = no tremor)
    :return: Percentage of detected tremor
    
Compute tremor constancy for a given set of tremor predictions.
Compute tremor constancy for a given set of tremor predictions .
def compute_tremor_constancy(tremor_classification_predictions):
    return tremor_classification_predictions.count(1)/float(len(tremor_classification_predictions))*100.
def compute_tremor_constancy ( tremor_classification_predictions ) : return tremor_classification_predictions . count ( 1 ) / float ( len ( tremor_classification_predictions ) ) * 100.
Compute tremor constancy for a given set of tremor predictions.
Compute tremor constancy for a given set of tremor predictions .
'''
    Compute tremor constancy for a given set of tremor predictions.
    :param tremor_classification_predictions: Tremor predictions as determined by tremor classifier. Binary predictions (1 = tremor, 0 = no tremor)
    :return: Percentage of detected tremor
    '''
Percentage of detected tremor
Percentage of detected tremor
tremor_classification_predictions
Tremor predictions as determined by tremor classifier. Binary predictions (1 = tremor, 0 = no tremor)
Tremor predictions as determined by tremor classifier . Binary predictions ( 1 = tremor 0 = no tremor )