<jupyter_start><jupyter_text>Template for test<jupyter_code>from pred import Predictor
from pred import sequence_vector
from pred import chemical_vector<jupyter_output>/Users/mark/anaconda3/lib/python3.6/site-packages/sklearn/cross_validation.py:44: DeprecationWarning: This module was deprecated in version 0.18 in favor of the model_selection module into which all the refactored classes and functions are moved. Also note that the interface of the new CV iterators are different from that of this module. This module will be removed in 0.20.
  "This module will be removed in 0.20.", DeprecationWarning)<jupyter_text>Controlling for Random Negatve vs Sans Random in Imbalanced Techniques using S, T, and Y Phosphorylation.Included is N Phosphorylation however no benchmarks are available, yet. Training data is from phospho.elm and benchmarks are from dbptm.<jupyter_code>par = ["pass", "ADASYN", "SMOTEENN", "random_under_sample", "ncl", "near_miss"]
for i in par:
    print("y", i)
    y = Predictor()
    y.load_data(file="Data/Training/clean_s_filtered.csv")
    y.process_data(vector_function="sequence", amino_acid="S", imbalance_function=i, random_data=0)
    y.supervised_training("mlp_adam")
    y.benchmark("Data/Benchmarks/phos_stripped.csv", "S")
    del y
    print("x", i)
    x = Predictor()
    x.load_data(file="Data/Training/clean_s_filtered.csv")
    x.process_data(vector_function="sequence", amino_acid="S", imbalance_function=i, random_data=1)
    x.supervised_training("mlp_adam")
    x.benchmark("Data/Benchmarks/phos_stripped.csv", "S")
    del x<jupyter_output>y pass
Loading Data
Loaded Data
Working on Data
Sample Vector [11, 10, 3, 10, 10, 19, 10, 9, 10, 19, 10, 19, 10, -1.3384615384615386, 112.93846153846157, 0.0]
Finished working with Data
Training Data Points: 200363
Test Data Points: 50091
Starting Training
Done training
Test Results
Sensitivity: 0.0056107034958998705
Specificity : 0.9990691521936164
Accuracy: 0.8152562336547483
ROC 0.502339927845
TP 52 FP 38 TN 40785 FN 9216



None
Cross: Validation: [ 0.81583886  0.81687329  0.81337965  0.81601118  0.81597125]
Number of data points in benchmark 65895
Benchmark Results 
Sensitivity: 0.0008880994671403197
Specificity : 0.9991842218916455
Accuracy: 0.9480081948554518
ROC 0.500036160679
TP 3 FP 51 TN 62466 FN 3375



None
x pass
Loading Data
Loaded Data
Working on Data
Sample Vector [14, 11, 20, 7, 9, 5, 10, 6, 3, 17, 16, 10, 13, -0.48461538461538467, 63.16923076923078, 0.15384615384615385]
Finished working with Data
Training Data Points: 200363
Test Data Points: 50091
Starting Training
[...]<jupyter_text>Y Phosphorylation<jupyter_code>par = ["pass", "ADASYN", "SMOTEENN", "random_under_sample", "ncl", "near_miss"]
for i in par:
    print("y", i)
    y = Predictor()
    y.load_data(file="Data/Training/clean_Y_filtered.csv")
    y.process_data(vector_function="sequence", amino_acid="Y", imbalance_function=i, random_data=0)
    y.supervised_training("mlp_adam")
    y.benchmark("Data/Benchmarks/phos_stripped.csv", "Y")
    del y
    print("x", i)
    x = Predictor()
    x.load_data(file="Data/Training/clean_Y_filtered.csv")
    x.process_data(vector_function="sequence", amino_acid="Y", imbalance_function=i, random_data=1)
    x.supervised_training("mlp_adam")
    x.benchmark("Data/Benchmarks/phos_stripped.csv", "Y")
    del x<jupyter_output>y pass
Loading Data
Loaded Data
Working on Data
Sample Vector [19, 3, 12, 12, 7, 12, 15, 5, 7, 19, 20, 16, 11, -0.18461538461538468, -30.653846153846157, 0.15384615384615385]
Finished working with Data
Training Data Points: 10099
Test Data Points: 2525
Starting Training
Done training
Test Results
Failed
TP 0 FP 1 TN 2418 FN 106



None
Cross: Validation: [ 0.95288994  0.95326733  0.95326733  0.95324881  0.95245642]
Number of data points in benchmark 23555
Benchmark Results 
Sensitivity: 0.975609756097561
Specificity : 1.0
Accuracy: 0.9999575461685417
ROC 0.987804878049
TP 40 FP 0 TN 23514 FN 1



None
x pass
Loading Data
Loaded Data
Working on Data
Sample Vector [9, 5, 2, 3, 12, 5, 15, 16, 17, 1, 15, 7, 3, 0.08461538461538445, 24.20846153846154, 0.3076923076923077]
Finished working with Data
Training Data Points: 10099
Test Data Points: 2525
Starting Training
Done training
Test Results
Failed
TP 0 FP 0 TN 2406 FN 119



None
Cross: Validation: [ 0.95249406  0.95287129  0.95326733  0.95[...]<jupyter_text>T Phosphorylation<jupyter_code>par = ["pass", "ADASYN", "SMOTEENN", "random_under_sample", "ncl", "near_miss"]
for i in par:
    print("y", i)
    y = Predictor()
    y.load_data(file="Data/Training/clean_t_filtered.csv")
    y.process_data(vector_function="sequence", amino_acid="T", imbalance_function=i, random_data=0)
    y.supervised_training("mlp_adam")
    y.benchmark("Data/Benchmarks/phos_stripped.csv", "T")
    del y
    print("x", i)
    x = Predictor()
    x.load_data(file="Data/Training/clean_t_filtered.csv")
    x.process_data(vector_function="sequence", amino_acid="T", imbalance_function=i, random_data=1)
    x.supervised_training("mlp_adam")
    x.benchmark("Data/Benchmarks/phos_stripped.csv", "T")
    del x<jupyter_output>y pass
Loading Data
Loaded Data
Working on Data
Sample Vector [2, 9, 2, 1, 18, 12, 20, 17, 11, 11, 20, 19, 3, -0.6461538461538461, 25.800000000000008, 0.0]
Finished working with Data
Training Data Points: 66323
Test Data Points: 16581
Starting Training
Done training
Test Results
Sensitivity: 0.026203734032099576
Specificity : 0.9917208752217622
Accuracy: 0.8139436704661962
ROC 0.508962304627
TP 80 FP 112 TN 13416 FN 2973



None
Cross: Validation: [ 0.81835725  0.81841756  0.81887817  0.81761158  0.81809409]
Number of data points in benchmark 47730
Benchmark Results 
Sensitivity: 0.0024330900243309003
Specificity : 0.9964728907241327
Accuracy: 0.9707940498638173
ROC 0.499452990374
TP 3 FP 164 TN 46333 FN 1230



None
x pass
Loading Data
Loaded Data
Working on Data
Sample Vector [3, 17, 9, 1, 17, 2, 20, 19, 19, 19, 4, 8, 10, -1.6076923076923078, 52.04615384615385, 0.0]
Finished working with Data
Training Data Points: 66323
Test Data Points: 16581
Starting Training
Done training
Test Res[...]
{'fraction_non_alphanumeric': 0.10204081632653061, 'fraction_numerical': 0.1702857142857143, 'mean_word_length': 4.982421875, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 1, 'word_list_counts': {'cursed_substrings.json': 7, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '55744', 'license': 'MIT', 'n_tokens_mistral': 3025, 'n_tokens_neox': 2195, 'n_words': 643, 'path': '.ipynb_checkpoints/Phosphorylation Sequence Tests -MLP -dbptm+ELM-VectorAvr.-phos_stripped-checkpoint.ipynb', 'repo_name': 'vzg100/ProtienFolding', 'size': '6125'}