From 0fe91019413b5527e9c2fd7b7c2243f2cdc2c862 Mon Sep 17 00:00:00 2001 From: Yukti Khosla <44090430+Yukti-09@users.noreply.github.com> Date: Tue, 18 Aug 2020 11:52:12 +0530 Subject: [PATCH] Create Linear(without inbuilt).m --- .../Activation Functions/Linear(without inbuilt).m | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 algorithms/machine_learning/Activation Functions/Linear(without inbuilt).m diff --git a/algorithms/machine_learning/Activation Functions/Linear(without inbuilt).m b/algorithms/machine_learning/Activation Functions/Linear(without inbuilt).m new file mode 100644 index 0000000..c4bbbc2 --- /dev/null +++ b/algorithms/machine_learning/Activation Functions/Linear(without inbuilt).m @@ -0,0 +1,9 @@ +%linear function without using inbuilt func +x = -10:0.01:10; +m = input('Enter the slope'); +y = zeros(size(x)); +y = m*x; +plot(x,y); +xlabel('x'); +ylabel('y'); +grid on