Skip to main content

Posts

Showing posts from June, 2021

Usefull R Commands

Most useful R commands You should know right Now. Start learning one by one. help() #give help regarding a command, e.g. help(hist)  c() #concatenate objects, e.g. x = c(3,5,8,9) or y = c(”Jack”,”Queen”,”King”) 1:19 #create a sequence of integers from 1 to 19  (…) #give arguments to a function, e.g. sum(x), or help(hist)  […] #select elements from a vector or list, e.g. x[2] gives 5, x[c(2,4)] gives 5 9 for x as above matrix() #fill in (by row) the values from y in a matrix of 4 rows and 3 columns by giving #m = matrix(y,4,3,byrow=T)  dim() #gives the number of rows and the number of columns of a matrix, or a data frame head() #gives the first 6 rows of a large matrix, or data frame  tail() #gives the last 6 rows of a large matrix, or data frame  m[ ,3] #gives the 3rd column of the matrix m  m[2, ] #gives the 2nd row of the matrix m  = or <- #assign something to a variable, e.g. x = c(”a”,”b”,”b”,”e”)  == #ask whether two things are equal, e.g. x = c(3,5,6,3) and then x == 3 g

Introduction to OS-Operating System

What is Operating System   The Operating System is a program with the following features  An operating system is a system software that acts as an interface between the user and the computer hardware. It is an integrated set of specialized programs used to manage overall resources and operations of the computer.  It is a specialized software that controls and monitors the execution ofall other programs that reside in the computer, including application Unit    Intorduction to Opeating System all other programs that reside in the computer, including applicationprograms and other system software.  Objectives of Operating System To make the computer system convenient to use in an efficientmanner. To hide the details of the hardware resources from the users.To provide users a convenient interface to use the computer system. To act as an intermediary between the hardware and its users, makingit easier for the users to access and use other resources.  To manage the resources of a computer sy

Shell Script

A shell is a program that interprets commands and acts as an interface between application layer and kernel of OS A Linux shell is command interpreter that interprets a user command which are directly entered by user or which can be read from a file called as shell programming or shell. You can get the name of your shell prompt, with following command : Shell Scripts Syntax: #echo $SHELL Output: /bin/bash  When a group of commands has to execute regularly, it isbetter to store in a file. All such files are called shell scripts, shell program, or shell The extension is .sh is used for shell program scripting. You can get the name of your shell prompt, with followingprocedures. Steps to create shell scripts 1. Open the terminal. Go to the directory where you want tocreate your script. 2. Create a file using vi editor(or any other editor). Name thescript file with extension .sh 3. To run your script in a certain shell, start your script with #!followed by the shell name. The s

Relational database design

Closure Of Functional Dependency Introduction The Closure Of Functional Dependency means the complete set of all possible attributes that can be functionally derived from given functional dependency using the inference rules known as Armstrong’s Rules. If “F” is a functional dependency then closure of functional dependency can be denoted using “{F}+”. There are three steps to calculate closure of functional dependency.  These are Step-1 : Add the attributes which are present on Left Hand Side in the original functional dependency.       Step-2 : Now, add the attributes present on the Right Hand Side of the functional dependency.       Step-3 : With the help of attributes present on Right Hand Side, check the other attributes that can be derived from the other given functional dependencies.       Repeat this process until all the possible attributes which can be derived are added in the closure. Closure Of Functional Dependency Examples Example-1 : Consider the table student_details hav

SQL

The commercial database system requires a more user friendly query language . SQL i.e. structured query language ,it uses a combination of relational algebra and relational calculus constructs. The user can write SQL statement and submit it to the database. DBMS will retrieve the appropriate data from disk and return it to user. Basic structure:- The SQL expression consists of 3 clauses or components. Select<list of attributes> From<table name> Where<condition>; Parts of SQL DDL Commands Create Table Drop Table Alter Table DML Commands Insert Update Delete A relational database consists of multiple related tables. A table consists of rows and columns. Tables allow you to store structured data like customers, products, employees, etc. To create a new table, you use the CREATE TABLE statement. The following illustrates the basic syntax of the CREATE TABLE statement: CREATE TABLE [IF NOT EXISTS] table_name ( column1 datatype(length) column_contraint,