MACHINE LEARNING RECIPES
DATA CLEANING PYTHON
DATA MUNGING
PANDAS CHEATSHEET
ALL TAGS
# What happens when you mutiply 2 vectors of unequal length in R?

This recipe explains what happens when you mutiply 2 vectors of unequal length in R

What happens when you multiply 2 vectors of unequal length in R? When two vectors of unequal length are multiplied, the vector with shorter length will be recycled in such a way that it will match the length of the longer vector and then perform the multiplication operation. This recycling of the shorter vector is known as the recycling rule. This recipe performs multiplication of unequal vector lengths.

Two vectors (for e.g : numeric) of unequal lengths are defined , here the length of vector b is a multiple of length of vector b

```
a <- c(1:10)
b <- c(1:5)
print(length(a))
print(length(b))
print(a)
print(b)
```

The shorter vector b gets recycled and forms a vector of length (1:10) in order to match the length of vector a..

```
print(a*b)
```

Two vectors (for e.g - numeric) of unequal lengths are defined, here the length of vector b is not a multiple of the length of vector b.

```
x <- c(1:10)
y <- c(1:4)
print(length(x))
print(length(y))
print(x)
print(y)
```

"Output of the code is:" [1] 1 2 3 4 5 6 7 8 9 10 [1] 1 2 3 4

A warning message is displayed when the length of the two vectors are not in proportion —

```
print(x*y)
```

"Output of the code is" Warning message in x * y: “longer object length is not a multiple of shorter object length” [1] 1 4 9 16 5 12 21 32 9 20

In this project, we will use time-series forecasting to predict the values of a sensor using multiple dependent variables. A variety of machine learning models are applied in this task of time series forecasting. We will see a comparison between the LSTM, ARIMA and Regression models. Classical forecasting methods like ARIMA are still popular and powerful but they lack the overall generalizability that memory-based models like LSTM offer. Every model has its own advantages and disadvantages and that will be discussed. The main objective of this article is to lead you through building a working LSTM model and it's different variants such as Vanilla, Stacked, Bidirectional, etc. There will be special focus on customized data preparation for LSTM.

MLOps on GCP - Solved end-to-end MLOps Project to deploy a Mask RCNN Model for Image Segmentation as a Web Application using uWSGI Flask, Docker, and TensorFlow.

In this data science project, you will learn how to perform market basket analysis with the application of Apriori and FP growth algorithms based on the concept of association rule learning.

Classification ML Project for Beginners - A Hands-On Approach to Implementing Different Types of Classification Algorithms in Machine Learning for Predictive Modelling

Use the Adult Income dataset to predict whether income exceeds 50K yr based oncensus data.

Estimating churners before they discontinue using a product or service is extremely important. In this ML project, you will develop a churn prediction model in telecom to predict customers who are most likely subject to churn.

In this NLP Project, you will learn how to use the popular topic modelling library Gensim for implementing two state-of-the-art word embedding methods Word2Vec and FastText models.

Want to search images of clothes which have text on them? Then this project talks through how we can classify an image whether it has text on it or not. For this we use state of the model called as inception and try and deepdive into how it works on our dataset

In this data science project, we will predict the credit card fraud in the transactional dataset using some of the predictive models.

Learn the basic aspects of chatbot development and open source conversational AI RASA to create a simple AI powered chatbot on your own.