OSDT icon indicating copy to clipboard operation
OSDT copied to clipboard

can you please share some simple, but meaningful toy example like pycorels

Open Sandy4321 opened this issue 5 years ago • 2 comments

can you please share some simple, but meaningful toy example like pycorels to make sure it works for example like https://github.com/fingoldin/pycorels Toy dataset (See picture example above) from corels import CorelsClassifier

["loud", "samples"] is the most verbose setting possible C = CorelsClassifier(max_card=2, c=0.0, verbosity=["loud", "samples"])

4 samples, 3 features X = [[1, 0, 1], [0, 0, 0], [1, 1, 0], [0, 1, 0]] y = [1, 0, 0, 1]

Feature names features = ["Mac User", "Likes Pie", "Age < 20"]

Fit the model C.fit(X, y, features=features, prediction_name="Has a dirty computer")

Print the resulting rulelist print(C.rl())

Predict on the training set print(C.predict(X))

Sandy4321 avatar Feb 07 '20 22:02 Sandy4321

Can you please add simple example I do have time this Sunday so would try You should be interesting in second opinion how your code works, or you have some reservations And need more time to debug?

Sandy4321 avatar Feb 16 '20 00:02 Sandy4321

any progress in this direction? it would be simple for you to create such a n example?

Sandy4321 avatar Apr 05 '20 18:04 Sandy4321