Statistician. Data Analyst. SQL Addict.

Image for post
Image for post

Hello, my name is Riza Purnaramadhan, i was born in 1999, i’m from Indonesia.

I’m statistics student at Islamic University of Indonesia. I love data science, data science is like my daily food, I’m very greedy to keep learning data, some of the skills I have about data analysis are such as Customer Segmentation, Overall Analysis, Growth Analysis, Burn Rate Analysis , Market Basket Analysis, Twitter Analysis, Exploration Data Analysis, Statistics Hypothesis, Data Visualization, Data Storytelling, etc. About Machine Learning i also like it.

Many may ask why I could choose to study statistics, Yes, it cannot be denied that…


Explanation and examples analogies

Image for post
Image for post

Perhaps many are wondering why alpha is always used as a reference and is the focus of research, maybe even some statistics students don’t know it. On this occasion, I intend to explain this and provide an example of a simple analogy that is hopefully easy to understand.

Table of Contents

  • Type I Error
  • Type II Error
  • Explanation & Simple Examples Analogies

Type I Error

Type I Error in statistics is symbolized by α (alpha), Type I Error is an error because it rejects the null hypothesis, even though the null hypothesis is true. …


Face recognition stage

Image for post
Image for post

Resuming the previous material about facial recognition, then after successful training, it can be continued with the initial face capture coding, the previous coding was as follows,

import cv2, os
import numpy as np
from PIL import Imagerecognizer = cv2.face.LBPHFaceRecognizer_create()
detector = cv2.CascadeClassifier("haarcascade_frontalface_default.xml");def getImagesWithLabels(path):
imagePaths=[os.path.join(path,f) for f in os.listdir(path)] faceSamples=[]
Ids=[] for imagePath in imagePaths:
pilImage=Image.open(imagePath).convert('L')
imageNp=np.array(pilImage,'uint8')
Id=int(os.path.split(imagePath)[-1].split(".")[1])
faces=detector.detectMultiScale(imageNp)
for (x,y,w,h) in faces:
faceSamples.append(imageNp[y:y+h,x:x+w])
Ids.append(Id)
return faceSamples, Idsfaces, Ids = getImagesWithLabels('DataSet')
recognizer.train(faces, np.array(Ids))
recognizer.save('training/training.xml')

then a little command will be added to mark the face image…


Continuously recognizes images in the dataset folder

Image for post
Image for post

After we have succeeded in capturing or detecting facial images in one frame in the previous material, then it is time for us to make coding to teach the machine to recognize these faces.

In this material, we will try to recognize the images in the dataset folder continuously, in the sense of training the system to correctly recognize these facial images. Therefore we need a recognizer algorithm that has been provided by OpenCV, namely

recognizer = cv2.face.LBPHFaceRecognizer_create()

then defined a loop function to learn to recognize the image and each label

def getImagesWithLabels(path):

so what is needed, take image…


Try to capture faces and generate face data for further processing

Image for post
Image for post

We will continue the previous material so that the computer can recognize faces. We will take back the coding from the previous material as follows

# Import module 
import cv2, time# capture command with camera
camera = 0
video = cv2.VideoCapture(camera, cv2.CAP_DSHOW)
a=0
while True :
a = a+1
check, frame = video.read()print(check)
print(frame)gray=cv2.cvtColor(frame,cv2.COLOR_BGR2GRAY)cv2.imshow("capture1",gray)
#cv2.waitKey(0)key = cv2.waitKey(1)
if key == ord('q') :
breakprint(a)
# Command closes camera
video.release()cv2.destroyAllWindows()

From the coding, it only displays the image as a whole and does not point precisely to the face, so here we need an algorithm to detect faces from the entire image…


Know how a computer captures a video image in the form of a pixel value matrix

Image for post
Image for post

On this occasion, we will try to do Face Recognition using python from the basics of knowing how computers capture images.

First, we import the necessary modules (make sure you have previously installed opencv-python). I write the code using Notepad ++.

# Import module 
import cv2, time

then make a command to capture the object from our computer camera then close it

video = cv2.VideoCapture(0)
video.release()

thus, the whole command looks like this,

# Import module 
import cv2, time
video = cv2.VideoCapture(0)
video.release()

then save the code with a name, for example, “capture1.py” in a folder, for example, C:\Users\asus\capture1

then…


A brief explanation and case examples

Image for post
Image for post

In this article I intend to briefly explain what is a Monte Carlo simulation with some examples of cases of Monte Carlo simulation using Excel, remember that Excel is only a tool! The most important thing is how you can understand the concept well and dig deeper!

Table of Contents

  • What is simulation?
  • What is Monte Carlo Simulation?
  • Monte Carlo Simulation Algorithm
  • Case Examples

What is Simulation?

Okay, before going into the Monte Carlo simulation, we must first understand what simulation is.

There are several meanings about simulation which are essentially the same:

“Simulation is to imitate a real process, called a system, through a model…


Initial SQL lessons a Data Analyst should know

Image for post
Image for post

Currently, if we observe, most of the job vacancies as a data analyst in companies who have implemented IT systems, require SQL as analysis tool expertise, therefore SQL skills are skills that must be mastered by someone who wants to work as a data analyst.

In this article, I intend to introduce an initial SQL lesson for someone who is looking for a career as a data analyst.

Table of Contents

  1. About SQL
  2. Types of SQL Commands
  3. Relational Database Management System (RDBMS)
  4. Query Example

About SQL

What is SQL?

SQL which stands for Structured Query Language is the standard computer language used for a database system — or…


Image for post
Image for post

Assalamu’alaikum Warahmatullahi Wabarakatuh.

Pada kesempatan kali ini saya akan membahas contoh sederhana Neural Network dan sekaligus implementasinya, terkait penjelasan apa itu Neural Network bisa dibaca di tulisannya saya sebelumnya yang berjudul Prediksi Menggunakan Artificial Neural Network dengan R Studio, Studi Kasus : Data Titanic. Oke langsung saja kita praktekan!

Table of Contents

  1. Simple Example
  2. Implementation

Simple Example

Oke, pertama jangan lupa siapkan librarynya terlebih dahulu, kita akan memakai library neuralnet, Kalo belum ada install terlebih dahulu packagenya ya.

library(neuralnet)

kita mempunyai data seperti berikut yang akan digunakan untuk melatih fungsineuralnetdi R dan kemudian menguji keakuratan jaringan neural yang dibangun


Image for post
Image for post

Bismillahirrahmanirrahim, Assalamu’alaikum Warahmatullahi Wabarakatuh. Pada kesempatan kali ini saya akan membahasa sedikit tentang analisis cluster.

Clustering

Pada dasarnya analisis cluster akan menghasilkan sejumlah kelompok. Analisis cluster merupakan salah satu teknik yang bertujuan untuk mengidentifikasi secluster obyek yang mempunyai kemiripan (similarity) karakteristik tertentu yang dapat dipisahkan dengan cluster obyek lainnya, sehingga obyek yang berada dalam cluster yang sama relative lebih homogen daripada obyek yang berada pada cluster yang berbeda. Menurut buku Supranto (2004) yang berjudul “Analisis Multivariat, Arti dan Interpretasi”, cluster analysis merupakan suatu teknik yang digunakan untuk mengklasifikasi objek atau ke dalam cluster yang relatif homogen disebut cluster. …

Riza Purnaramadhan

Statistician | Data Analyst | SQL Addict

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store