title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Import and Merge Multiple CSV Files in R - GeeksforGeeks | 17 Jun, 2021
In this article, we will be looking at the approach to merge multiple CSV files in the R programming language.
dplyr: This is a structure of data manipulation that provides a uniform set of verbs, helping to resolve the most frequent data manipulation hurdles.
plyr: plyr is an R package that makes it simp... | [
{
"code": null,
"e": 24923,
"s": 24892,
"text": " \n17 Jun, 2021\n"
},
{
"code": null,
"e": 25034,
"s": 24923,
"text": "In this article, we will be looking at the approach to merge multiple CSV files in the R programming language."
},
{
"code": null,
"e": 25184,
"... |
Factor Analysis 101. Can we reduce the number of variables... | by Jeppe Andersen | Towards Data Science | Even though this is an introductory look at Factor Analysis, I assume that the reader has some knowledge in math and statistics and want to learn about multivariate statistical analysis. This article will focus on the theoretical understanding of Factor Analysis and I will thus leave out the coding related to this subj... | [
{
"code": null,
"e": 534,
"s": 172,
"text": "Even though this is an introductory look at Factor Analysis, I assume that the reader has some knowledge in math and statistics and want to learn about multivariate statistical analysis. This article will focus on the theoretical understanding of Factor A... |
Convert a JSON object to XML format in Java?
| A JSON is a lightweight data-interchange format and the format of JSON is like a key-value pair. We can convert a JSONObject into an XML format using org.json.XML class, this provides static methods to convert an XML text into a JSONObject and to convert a JSONObject into an XML text. The XML.toString() method convert ... | [
{
"code": null,
"e": 1443,
"s": 1062,
"text": "A JSON is a lightweight data-interchange format and the format of JSON is like a key-value pair. We can convert a JSONObject into an XML format using org.json.XML class, this provides static methods to convert an XML text into a JSONObject and to conver... |
Product of maximum in first array and minimum in second | Practice | GeeksforGeeks | Given two arrays of A and B respectively of sizes N1 and N2, the task is to calculate the product of the maximum element of the first array and minimum element of the second array.
Example 1:
Input : A[] = {5, 7, 9, 3, 6, 2},
B[] = {1, 2, 6, -1, 0, 9}
Output : -9
Explanation:
The first array is 5 7 9 3 6 2.
T... | [
{
"code": null,
"e": 419,
"s": 238,
"text": "Given two arrays of A and B respectively of sizes N1 and N2, the task is to calculate the product of the maximum element of the first array and minimum element of the second array."
},
{
"code": null,
"e": 430,
"s": 419,
"text": "Examp... |
MFC - Controls Management | In MFC applications, after visually adding a control to your application, if you want to refer to it in your code, you can declare a variable based on, or associated with that control. The MFC library allows you to declare two types of variables for some of the controls used in an application a value or a control varia... | [
{
"code": null,
"e": 2392,
"s": 2067,
"text": "In MFC applications, after visually adding a control to your application, if you want to refer to it in your code, you can declare a variable based on, or associated with that control. The MFC library allows you to declare two types of variables for som... |
Magic Number | Practice | GeeksforGeeks | A magic number is defined as a number that can be expressed as a power of 5 or sum of unique powers of 5. First few magic numbers are 5, 25, 30(5 + 25), 125, 130(125 + 5), ....
Given the value of n, find the n'th Magic number modulo 109+7.
Example 1:
Input: n = 1
Output: 5
Explanation: 1'st Magic number is 5.
​Examp... | [
{
"code": null,
"e": 478,
"s": 238,
"text": "A magic number is defined as a number that can be expressed as a power of 5 or sum of unique powers of 5. First few magic numbers are 5, 25, 30(5 + 25), 125, 130(125 + 5), ....\nGiven the value of n, find the n'th Magic number modulo 109+7."
},
{
... |
How to implement Linear Regression with PyTorch | by Dorian Lazar | Towards Data Science | Probably, implementing linear regression with PyTorch is an overkill. This library was made for more complicated stuff like neural networks, complex deep learning architectures, etc. Nevertheless, I think that using it for implementing a simpler machine learning method, like linear regression, is a good exercise for th... | [
{
"code": null,
"e": 532,
"s": 172,
"text": "Probably, implementing linear regression with PyTorch is an overkill. This library was made for more complicated stuff like neural networks, complex deep learning architectures, etc. Nevertheless, I think that using it for implementing a simpler machine l... |
How to change the width of whisker lines in a boxplot using ggplot2 in R? | In R, by default the whisker lines are as wide as the box of the boxplot but it would be great if we reduce that width or increase it because it will get attention of the viewer in that way. This can be done by using the width argument inside the stat_boxplot function of ggplot2 package. Check out the below example to ... | [
{
"code": null,
"e": 1407,
"s": 1062,
"text": "In R, by default the whisker lines are as wide as the box of the boxplot but it would be great if we reduce that width or increase it because it will get attention of the viewer in that way. This can be done by using the width argument inside the stat_b... |
Difference between stopPropagation vs stopImmediatePropagation in JavaScript - GeeksforGeeks | 23 Jan, 2022
An event propagates or bubbles till the window object-level every time a registered event is called. For example, Let us consider a parent div element (“Div Parent”) that contains another child div element (“Div child”), and for both, a click event is registered. If child div is clicked, the event will be ... | [
{
"code": null,
"e": 24909,
"s": 24881,
"text": "\n23 Jan, 2022"
},
{
"code": null,
"e": 25849,
"s": 24909,
"text": "An event propagates or bubbles till the window object-level every time a registered event is called. For example, Let us consider a parent div element (“Div Parent... |
How to Count the Number of Vowels in a string using Python? | Declare a string object containing all vowels.
>>> vowels='aeiou'
Set up a count variable initialize to 0
>>> count=0
Check if each character of input string belong to vowel string. If yes increment the count
>>> string='Hello How are you?'
>>> for s in string:
if s in vowels: count=count+1
In the end displ... | [
{
"code": null,
"e": 1109,
"s": 1062,
"text": "Declare a string object containing all vowels."
},
{
"code": null,
"e": 1128,
"s": 1109,
"text": ">>> vowels='aeiou'"
},
{
"code": null,
"e": 1168,
"s": 1128,
"text": "Set up a count variable initialize to 0"
},... |
Write a Regular Expression to remove all special characters from a JavaScript String? | To remove all special characters from a JavaScript string, you can try to run the following code −
<html>
<head>
<script>
var str = "@!Welcome to our website$$";
document.write(str);
// Removing Special Characters
document.write("<br>"+str.replace(/[^\w\s]/gi, ''))... | [
{
"code": null,
"e": 1161,
"s": 1062,
"text": "To remove all special characters from a JavaScript string, you can try to run the following code −"
},
{
"code": null,
"e": 1444,
"s": 1161,
"text": "<html>\n <head>\n <script>\n var str = \"@!Welcome to our website$$\... |
Maximum area of a Rectangle that can be circumscribed about a given Rectangle of size LxW - GeeksforGeeks | 27 Apr, 2021
Given a rectangle of dimensions L and W. The task is to find the maximum area of a rectangle that can be circumscribed about a given rectangle with dimensions L and W.
Examples:
Input: L = 10, W = 10Output: 200
Input: L = 18, W = 12Output: 450
Approach: Let below is the given rectangle EFGH of dimensi... | [
{
"code": null,
"e": 26671,
"s": 26643,
"text": "\n27 Apr, 2021"
},
{
"code": null,
"e": 26840,
"s": 26671,
"text": "Given a rectangle of dimensions L and W. The task is to find the maximum area of a rectangle that can be circumscribed about a given rectangle with dimensions L an... |
How to use .data files from UCI. Don’t be frightened by the .data... | by Jacob Toftgaard Rasmussen | Towards Data Science | You will learn how to use the data sets from UCI that come with the .data file type in this quick article.
Kaggle.com is a great choice for finding data to use in your data science projects. The site is filled with interesting data sets, notebooks from other scientists and tutorials. All the data sets I have encountere... | [
{
"code": null,
"e": 279,
"s": 172,
"text": "You will learn how to use the data sets from UCI that come with the .data file type in this quick article."
},
{
"code": null,
"e": 576,
"s": 279,
"text": "Kaggle.com is a great choice for finding data to use in your data science proje... |
What are the modes a file can be opened using Python? | Files in python can be opened in the following modes.
These modes can be used in combinations and need to be passed as the second argument when opening a file. If you don't specify a mode, files are opened in readonly text mode.
f = open("test.txt") # Equivalent to rt or race
f = open("test.txt", 'w') # Write in text... | [
{
"code": null,
"e": 1116,
"s": 1062,
"text": "Files in python can be opened in the following modes."
},
{
"code": null,
"e": 1293,
"s": 1118,
"text": "These modes can be used in combinations and need to be passed as the second argument when opening a file. If you don't specify a... |
JavaScript TypeError - Setting getter-only property "x" - GeeksforGeeks | 18 Aug, 2020
This JavaScript exception setting getter-only property works in strict-mode only and occurs if the user tries to set a new value to a property for which only a getter is specified.
Message:
TypeError: Assignment to read-only properties is
not allowed in strict mode (Edge)
TypeError: setting get... | [
{
"code": null,
"e": 24909,
"s": 24881,
"text": "\n18 Aug, 2020"
},
{
"code": null,
"e": 25090,
"s": 24909,
"text": "This JavaScript exception setting getter-only property works in strict-mode only and occurs if the user tries to set a new value to a property for which only a get... |
DateTime.IsDaylightSavingTime() Method in C# - GeeksforGeeks | 06 Feb, 2019
This method is used to indicate whether this instance of DateTime is within the daylight saving time range for the current time zone.
Syntax: public bool IsDaylightSavingTime ();
Return Value: This method returns true if the value of the Kind property is Local or Unspecified and the value of this instance ... | [
{
"code": null,
"e": 23911,
"s": 23883,
"text": "\n06 Feb, 2019"
},
{
"code": null,
"e": 24045,
"s": 23911,
"text": "This method is used to indicate whether this instance of DateTime is within the daylight saving time range for the current time zone."
},
{
"code": null,
... |
How to quickly swap two arrays of same size in C++? - GeeksforGeeks | 28 May, 2017
Given two arrays a[] and b[] of same size, we need to swap their contents.
Example :
Input : a[] = {1, 2, 3, 4}
b[] = {5, 6, 7, 8}
Output : a[] = {5, 6, 7, 8}
b[] = {1, 2, 3, 4}
A simple solution is to iterate over elements of both arrays and swap them one by one.
A quick solution is to u... | [
{
"code": null,
"e": 24043,
"s": 24015,
"text": "\n28 May, 2017"
},
{
"code": null,
"e": 24118,
"s": 24043,
"text": "Given two arrays a[] and b[] of same size, we need to swap their contents."
},
{
"code": null,
"e": 24128,
"s": 24118,
"text": "Example :"
},... |
Python eval() built-in-function. Let us understand the eval()... | by Tanu N Prabhu | Towards Data Science | Let us understand the eval() built-in-function in python.
This would be a short article about eval function in python, wherein I would be explaining to you about eval function, its syntax, and few questions that are often asked in interviews so that you clearly understand it and answer those questions in ease. To get t... | [
{
"code": null,
"e": 230,
"s": 172,
"text": "Let us understand the eval() built-in-function in python."
},
{
"code": null,
"e": 548,
"s": 230,
"text": "This would be a short article about eval function in python, wherein I would be explaining to you about eval function, its synta... |
DateField - Django Models - GeeksforGeeks | 24 Aug, 2021
DateField is a field that stores date, represented in Python by a datetime.date instance. As the name suggests, this field is used to store an object of date created in python. The default form widget for this field is a TextInput. The admin can add a JavaScript calendar and a shortcut for “Today” explicit... | [
{
"code": null,
"e": 23859,
"s": 23831,
"text": "\n24 Aug, 2021"
},
{
"code": null,
"e": 24170,
"s": 23859,
"text": "DateField is a field that stores date, represented in Python by a datetime.date instance. As the name suggests, this field is used to store an object of date creat... |
Display hello world using React.js | create-react-app is a command to create a React.js project with default configuration. Create-react-app will help in running react applications. Command will be executed on npm or yarn
If npm and node.js is installed on computer, install create-react-app globally with command −
npm install –g create-react-app
Creation ... | [
{
"code": null,
"e": 1247,
"s": 1062,
"text": "create-react-app is a command to create a React.js project with default configuration. Create-react-app will help in running react applications. Command will be executed on npm or yarn"
},
{
"code": null,
"e": 1341,
"s": 1247,
"text"... |
Create index on create table in MySQL? | Let us first create a table and index −
mysql> create table DemoTable
(
StudentId int NOT NULL AUTO_INCREMENT PRIMARY KEY,
StudentFirstName varchar(20),
StudentAge int,
StudentCountryName varchar(100),
INDEX first_Name_index(StudentFirstName)
);
Query OK, 0 rows affected (1.01 sec)
Check the descri... | [
{
"code": null,
"e": 1102,
"s": 1062,
"text": "Let us first create a table and index −"
},
{
"code": null,
"e": 1366,
"s": 1102,
"text": "mysql> create table DemoTable\n (\n StudentId int NOT NULL AUTO_INCREMENT PRIMARY KEY,\n StudentFirstName varchar(20),\n StudentAge in... |
Minimum number of insertions in given String to remove adjacent duplicates - GeeksforGeeks | 21 Jan, 2022
Given a string str of size N, the task is to find the minimum number of additions in the string such that no two consecutive elements are the same.
Examples:
Input: str=”rrg” Output: 1Explanation: Add an element between two r’s
Input: str=”rrrrr”Output: 4
Approach: The above problem can be solved using the... | [
{
"code": null,
"e": 25859,
"s": 25831,
"text": "\n21 Jan, 2022"
},
{
"code": null,
"e": 26007,
"s": 25859,
"text": "Given a string str of size N, the task is to find the minimum number of additions in the string such that no two consecutive elements are the same."
},
{
"... |
DATESINPERIOD function | Returns a table that contains a column of dates that begins with the start_date and continues for the specified number_of_intervals.
DATESINPERIOD (<dates>, <start_date>, <number_of_intervals>, <interval>)
dates
A column that contains dates.
start_date
A date expression.
number_of_intervals
An integer that specifies ... | [
{
"code": null,
"e": 2134,
"s": 2001,
"text": "Returns a table that contains a column of dates that begins with the start_date and continues for the specified number_of_intervals."
},
{
"code": null,
"e": 2209,
"s": 2134,
"text": "DATESINPERIOD (<dates>, <start_date>, <number_of_... |
Comments in C# - GeeksforGeeks | 07 May, 2019
Comments are used for explaining the code and are used in a similar manner as in Java, C or C++. Compilers ignore the comment entries and do not execute them. Generally, programming languages contain two types of comments but in C#, there are 3 Types of comments :
Single Line Comments : It is used to comme... | [
{
"code": null,
"e": 23435,
"s": 23407,
"text": "\n07 May, 2019"
},
{
"code": null,
"e": 23700,
"s": 23435,
"text": "Comments are used for explaining the code and are used in a similar manner as in Java, C or C++. Compilers ignore the comment entries and do not execute them. Gene... |
Bootstrap - Tables | Bootstrap provides a clean layout for building tables. Some of the table elements supported by Bootstrap are −
<table>
Wrapping element for displaying data in a tabular format
<thead>
Container element for table header rows (<tr>) to label table columns.
<tbody>
Container element for table rows (<tr>) in the body of th... | [
{
"code": null,
"e": 3442,
"s": 3331,
"text": "Bootstrap provides a clean layout for building tables. Some of the table elements supported by Bootstrap are −"
},
{
"code": null,
"e": 3450,
"s": 3442,
"text": "<table>"
},
{
"code": null,
"e": 3507,
"s": 3450,
"... |
ArrayList forEach() method in Java - GeeksforGeeks | 26 Nov, 2018
The forEach() method of ArrayList used to perform the certain operation for each element in ArrayList. This method traverses each element of the Iterable of ArrayList until all elements have been Processed by the method or an exception is raised. The operation is performed in the order of iteration if that... | [
{
"code": null,
"e": 24063,
"s": 24035,
"text": "\n26 Nov, 2018"
},
{
"code": null,
"e": 24466,
"s": 24063,
"text": "The forEach() method of ArrayList used to perform the certain operation for each element in ArrayList. This method traverses each element of the Iterable of ArrayL... |
Python | Pandas dataframe.clip() | 16 Nov, 2018
Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages and makes importing and analyzing data much easier.
Pandas dataframe.clip() is used to trim values at specified input threshold. We can use this ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n16 Nov, 2018"
},
{
"code": null,
"e": 242,
"s": 28,
"text": "Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages and makes imp... |
Incremental Compiler in Compiler Design | 26 Aug, 2020
Incremental Compiler is a compiler that generates code for a statement, or group of statements, which is independent of the code generated for other statements.
Examples :C/C++ GNU Compiler, Java eclipse platform, etc.
The Incremental Compiler is such a compilation scheme in which only modified source text... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 Aug, 2020"
},
{
"code": null,
"e": 189,
"s": 28,
"text": "Incremental Compiler is a compiler that generates code for a statement, or group of statements, which is independent of the code generated for other statements."
},
{
... |
How to create an empty DataFrame and append rows & columns to it in Pandas? | 02 Jul, 2020
Let’s discuss how to create an empty DataFrame and append rows & columns to it in Pandas. There are multiple ways in which we can do this task.
Method #1: Create a complete empty DataFrame without any column name or indices and then appending columns one by one to it.
# import pandas library as pdimport pa... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n02 Jul, 2020"
},
{
"code": null,
"e": 172,
"s": 28,
"text": "Let’s discuss how to create an empty DataFrame and append rows & columns to it in Pandas. There are multiple ways in which we can do this task."
},
{
"code": null,
... |
Create And Deploy A Stock Price Web Application using Python and Streamlit | 12 Nov, 2021
In this article, we are going to see how to create and deploy a stock price web application.
To create an amazing Web Application that deals with Data Science, we have a perfect platform to carry out this task. Streamlit and Python package builds and shares the data application in the fastest way possible.... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n12 Nov, 2021"
},
{
"code": null,
"e": 121,
"s": 28,
"text": "In this article, we are going to see how to create and deploy a stock price web application."
},
{
"code": null,
"e": 337,
"s": 121,
"text": "To create an ... |
How to create a menu using navbar-inverse in Bootstrap ? | 10 Oct, 2021
In this article, we will learn how to create a menu using the navbar-inverse in Bootstrap & will also understand its implementation through the example. The menu bar is a very important part while making a navigation bar for the website. We can create a menu bar along with inverse the color of the menu bar... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n10 Oct, 2021"
},
{
"code": null,
"e": 378,
"s": 28,
"text": "In this article, we will learn how to create a menu using the navbar-inverse in Bootstrap & will also understand its implementation through the example. The menu bar is a very... |
numpy.repeat() in Python | 28 Mar, 2022
The numpy.repeat() function repeats elements of the array – arr. Syntax :
numpy.repeat(arr, repetitions, axis = None)
Parameters :
array : [array_like]Input array.
repetitions : No. of repetitions of each array elements along the given axis.
axis : Axis along which we want to repeat values.... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 103,
"s": 28,
"text": "The numpy.repeat() function repeats elements of the array – arr. Syntax : "
},
{
"code": null,
"e": 147,
"s": 103,
"text": "numpy.repeat(arr, repetitions, ... |
Motherboard parts – North Bridge | 27 Sep, 2021
Motherboard comprises of many parts embedded in it. In this article, a part named North Bridge is being discussed. A motherboard has a chip set logic architecture consisting of two chipsets:
1. North Bridge
2. South Bridge
We have explained here, only North Bridge.
1. North Bridge : North bridge is also... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n27 Sep, 2021"
},
{
"code": null,
"e": 220,
"s": 28,
"text": "Motherboard comprises of many parts embedded in it. In this article, a part named North Bridge is being discussed. A motherboard has a chip set logic architecture consisting o... |
How to Create Boxplots by Group in Matplotlib? | 25 Jan, 2022
Boxplots by groups can be created using the matplotlib package, but, however, if you wish to make more customizations to your grouped box plot, then the seaborn package provides a go-to function that supports a wide variety of customizations to the grouped box plots. Matplotlib doesn’t provide an explicit ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n25 Jan, 2022"
},
{
"code": null,
"e": 502,
"s": 28,
"text": "Boxplots by groups can be created using the matplotlib package, but, however, if you wish to make more customizations to your grouped box plot, then the seaborn package provid... |
Lex Program to remove comments from C program | 11 Jul, 2022
Lex is a computer program that generates lexical analyzers. Lex reads an input stream specifying the lexical analyzer and outputs source code implementing the lexer in the C programming language.
The commands for executing the lex program are:
lex abc.l (abc is the file name)
cc lex.yy.c -efl
./a.out
Let’... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n11 Jul, 2022"
},
{
"code": null,
"e": 249,
"s": 53,
"text": "Lex is a computer program that generates lexical analyzers. Lex reads an input stream specifying the lexical analyzer and outputs source code implementing the lexer in the C ... |
Regular Expressions in Java | 09 Feb, 2022
Regular Expressions or Regex (in short) in Java is an API for defining String patterns that can be used for searching, manipulating, and editing a string in Java. Email validation and passwords are a few areas of strings where Regex is widely used to define the constraints. Regular Expressions are provided... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n09 Feb, 2022"
},
{
"code": null,
"e": 563,
"s": 54,
"text": "Regular Expressions or Regex (in short) in Java is an API for defining String patterns that can be used for searching, manipulating, and editing a string in Java. Email valid... |
How to set the Location of the TextBox in C#? | 29 Nov, 2019
In Windows forms, TextBox plays an important role. With the help of TextBox, the user can enter data in the application, it can be of a single line or of multiple lines. In TextBox, you are allowed to set the coordinates of the upper-left corner of the TextBox control relative to the upper-left corner of i... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n29 Nov, 2019"
},
{
"code": null,
"e": 450,
"s": 28,
"text": "In Windows forms, TextBox plays an important role. With the help of TextBox, the user can enter data in the application, it can be of a single line or of multiple lines. In Te... |
swap() in C++ | 06 Jul, 2022
The function std::swap() is a built-in function in the C++ Standard Template Library (STL) which swaps the value of two variables.
Syntax:
swap(a, b)
Parameters: The function accepts two mandatory parameters a and b which are to be swapped. The parameters can be of any data type.
Return Value: The functio... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n06 Jul, 2022"
},
{
"code": null,
"e": 183,
"s": 52,
"text": "The function std::swap() is a built-in function in the C++ Standard Template Library (STL) which swaps the value of two variables."
},
{
"code": null,
"e": 191,
... |
How to get the Daily News using Python | 14 Sep, 2021
In this article, we are going to see how to get daily news using Python. Here we will use Beautiful Soup and the request module to scrape the data.
bs4: Beautiful Soup(bs4) is a Python library for pulling data out of HTML and XML files. This module does not come built-in with Python. To install this type t... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n14 Sep, 2021"
},
{
"code": null,
"e": 201,
"s": 53,
"text": "In this article, we are going to see how to get daily news using Python. Here we will use Beautiful Soup and the request module to scrape the data."
},
{
"code": null... |
CheckBox in C# | 27 Sep, 2021
The CheckBox control is the part of windows form which is used to take input from the user. Or in other words, CheckBox control allows us to select single or multiple elements from the given list or it can provide us options like yes or no, true or false, etc. It can be displayed as an image or text or bot... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n27 Sep, 2021"
},
{
"code": null,
"e": 476,
"s": 28,
"text": "The CheckBox control is the part of windows form which is used to take input from the user. Or in other words, CheckBox control allows us to select single or multiple elements... |
Python PIL | Image filter with ImageFilter module | 25 Jun, 2019
The ImageFilter module contains definitions for a pre-defined set of filters, which can be be used with the Image.filter() method.
Image used:
Filters –The current version of the library provides the set of predefined image enhancement filters:
1. BLUR
# Importing Image and ImageFilter module from PIL pack... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n25 Jun, 2019"
},
{
"code": null,
"e": 159,
"s": 28,
"text": "The ImageFilter module contains definitions for a pre-defined set of filters, which can be be used with the Image.filter() method."
},
{
"code": null,
"e": 171,
... |
Plot choropleth maps with shapefiles using Geopandas | by Xiao Wang | Towards Data Science | Choropleth maps are useful and powerful visualisations which present data by areas or regions that colored or patterned according to the values. It is a bit like heatmaps but in geographic shapes.
I use it very often as it is really clear to users where the areas are and also handy for them to compare the data between ... | [
{
"code": null,
"e": 369,
"s": 172,
"text": "Choropleth maps are useful and powerful visualisations which present data by areas or regions that colored or patterned according to the values. It is a bit like heatmaps but in geographic shapes."
},
{
"code": null,
"e": 706,
"s": 369,
... |
C++ Inheritance | One of the most important concepts in object-oriented programming is that of inheritance. Inheritance allows us to define a class in terms of another class, which makes it easier to create and maintain an application. This also provides an opportunity to reuse the code functionality and fast implementation time.
When c... | [
{
"code": null,
"e": 2632,
"s": 2318,
"text": "One of the most important concepts in object-oriented programming is that of inheritance. Inheritance allows us to define a class in terms of another class, which makes it easier to create and maintain an application. This also provides an opportunity t... |
PHP | ereg_replace() Function - GeeksforGeeks | 13 Jun, 2018
The ereg_replace() is an inbuilt function in PHP and is used to search a string pattern in an other string. If pattern is found in the original string then it will replace matching text with a replacement string. You may refer to the article on Regular Expression for basic understanding of pattern matching... | [
{
"code": null,
"e": 25302,
"s": 25274,
"text": "\n13 Jun, 2018"
},
{
"code": null,
"e": 25637,
"s": 25302,
"text": "The ereg_replace() is an inbuilt function in PHP and is used to search a string pattern in an other string. If pattern is found in the original string then it will... |
How to run (Model-Agnostic Meta-Learning) MAML algorithm | by Rahul Bhadani | Towards Data Science | MAML is a class of meta-learning algorithms created by Stanford Research and UC Berkeley Alum Dr. Chelsea Finn. MAML was inspired by the idea behind the question that how much data is really needed to learn about something. Can we teach algorithms to learn how to learn?
In such a context, there are a few challenges wit... | [
{
"code": null,
"e": 443,
"s": 172,
"text": "MAML is a class of meta-learning algorithms created by Stanford Research and UC Berkeley Alum Dr. Chelsea Finn. MAML was inspired by the idea behind the question that how much data is really needed to learn about something. Can we teach algorithms to lear... |
How to find an element based on a data-attribute value using jQuery | To find an element based on a data-attribute value using jQuery is quite easy. Try to run the following code to find an element based on a data-attribute value −
Live Demo
<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
$(document).read... | [
{
"code": null,
"e": 1224,
"s": 1062,
"text": "To find an element based on a data-attribute value using jQuery is quite easy. Try to run the following code to find an element based on a data-attribute value −"
},
{
"code": null,
"e": 1234,
"s": 1224,
"text": "Live Demo"
},
{
... |
Generating random numbers in Java - GeeksforGeeks | 26 Oct, 2016
Java provides three ways to generate random numbers using some built-in methods and classes as listed below:
java.util.Random class
Math.random method : Can Generate Random Numbers of double type.
ThreadLocalRandom class
For using this class to generate random numbers, we have to first create an instance o... | [
{
"code": null,
"e": 24633,
"s": 24605,
"text": "\n26 Oct, 2016"
},
{
"code": null,
"e": 24742,
"s": 24633,
"text": "Java provides three ways to generate random numbers using some built-in methods and classes as listed below:"
},
{
"code": null,
"e": 24765,
"s": 2... |
Remove personal information from a text with Python — Part II | by Leo van der Meulen | Towards Data Science | This is a follow-up on my previous article on the removal of personal information from texts.
The GDPR is the General Data Protection Regulation by the European Union. Its purpose is to protect data of all European residents. Protecting data is also an intrinsic value of a developer. Protecting data in a row/column dat... | [
{
"code": null,
"e": 266,
"s": 172,
"text": "This is a follow-up on my previous article on the removal of personal information from texts."
},
{
"code": null,
"e": 590,
"s": 266,
"text": "The GDPR is the General Data Protection Regulation by the European Union. Its purpose is to ... |
How to explain neural networks using SHAP | by Gianluca Malato | Towards Data Science | Neural networks are fascinating and very efficient tools for data scientists, but they have a very huge flaw: they are unexplainable black boxes. In fact, they don’t give us any information about feature importance. Fortunately, there is a powerful approach we can use to interpret every model, even neural networks. It ... | [
{
"code": null,
"e": 514,
"s": 172,
"text": "Neural networks are fascinating and very efficient tools for data scientists, but they have a very huge flaw: they are unexplainable black boxes. In fact, they don’t give us any information about feature importance. Fortunately, there is a powerful approa... |
SVG <symbol> Element - GeeksforGeeks | 31 Mar, 2022
SVG stands for Scalable Vector Graphic. It can be used to make graphics and animations like in HTML canvas.
The SVG <symbol> element is used to define graphical template objects which can be instantiated by the <use> element. The use of symbol elements for graphics that are used multiple times in the same ... | [
{
"code": null,
"e": 24503,
"s": 24475,
"text": "\n31 Mar, 2022"
},
{
"code": null,
"e": 24611,
"s": 24503,
"text": "SVG stands for Scalable Vector Graphic. It can be used to make graphics and animations like in HTML canvas."
},
{
"code": null,
"e": 24849,
"s": 24... |
Python - Group each increasing and decreasing run in list - GeeksforGeeks | 06 Jun, 2021
Given a list, the task is to write a Python program to group each increasing and decreasing run. This is known as a monotonous grouping. A list is monotonic if it is either monotone increasing or monotone decreasing. A list A is monotone decreasing if for all i <= j, A[i] >= A[j].
Example:
Input : test_li... | [
{
"code": null,
"e": 23901,
"s": 23873,
"text": "\n06 Jun, 2021"
},
{
"code": null,
"e": 24184,
"s": 23901,
"text": "Given a list, the task is to write a Python program to group each increasing and decreasing run. This is known as a monotonous grouping. A list is monotonic if it... |
How to test if a parameter is provided to a function in JavaScript? | To test if a parameter is provided by a function, use the if condition and check with “undefined”.
Following is the code −
function checkingParameter(parameter) {
if (parameter !== undefined) {
console.log("Parameter is provided.");
} else {
console.log("Parameter is not provided.")
}
}
checkingPar... | [
{
"code": null,
"e": 1161,
"s": 1062,
"text": "To test if a parameter is provided by a function, use the if condition and check with “undefined”."
},
{
"code": null,
"e": 1185,
"s": 1161,
"text": "Following is the code −"
},
{
"code": null,
"e": 1425,
"s": 1185,
... |
10 Ways to Create a Stream in Java - GeeksforGeeks | 11 Dec, 2018
The Stream API, introduced in Java 8, it is used to process collections of objects. Stream is a sequence of objects, that supports many different methods which can be pipe lined to produce the desired result.
The features of Java stream are –
A stream is not a data structure alternatively it takes input fr... | [
{
"code": null,
"e": 24134,
"s": 24106,
"text": "\n11 Dec, 2018"
},
{
"code": null,
"e": 24343,
"s": 24134,
"text": "The Stream API, introduced in Java 8, it is used to process collections of objects. Stream is a sequence of objects, that supports many different methods which can... |
Cassandra - Cqlsh | This chapter introduces the Cassandra query language shell and explains how to use its commands.
By default, Cassandra provides a prompt Cassandra query language shell (cqlsh) that allows users to communicate with it. Using this shell, you can execute Cassandra Query Language (CQL).
Using cqlsh, you can
define a schema... | [
{
"code": null,
"e": 2384,
"s": 2287,
"text": "This chapter introduces the Cassandra query language shell and explains how to use its commands."
},
{
"code": null,
"e": 2571,
"s": 2384,
"text": "By default, Cassandra provides a prompt Cassandra query language shell (cqlsh) that a... |
SQL | Wildcard operators - GeeksforGeeks | 01 Sep, 2020
Prerequisite: SQL | WHERE ClauseIn the above mentioned article WHERE Clause is discussed in which LIKE operator is also explained, where you must have encountered the word wildcards now lets get deeper into Wildcards.
Wildcard operators are used with LIKE operator, there are four basic operators:
Basic sy... | [
{
"code": null,
"e": 23601,
"s": 23573,
"text": "\n01 Sep, 2020"
},
{
"code": null,
"e": 23820,
"s": 23601,
"text": "Prerequisite: SQL | WHERE ClauseIn the above mentioned article WHERE Clause is discussed in which LIKE operator is also explained, where you must have encountered... |
How to set maximum date in datepicker dialog in Android using Kotlin? | This example demonstrates how to set maximum date in datepicker dialog in Android using Kotlin.
Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 − Add the following code to res/layout/activity_main.xml.
<?xml version="1.0" encoding="... | [
{
"code": null,
"e": 1158,
"s": 1062,
"text": "This example demonstrates how to set maximum date in datepicker dialog in Android using Kotlin."
},
{
"code": null,
"e": 1287,
"s": 1158,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all... |
How to check if an instance of 8 puzzle is solvable? | 03 Nov, 2021
What is 8 puzzle? Given a 3×3 board with 8 tiles (every tile has one number from 1 to 8) and one empty space. The objective is to place the numbers on tiles in order using the empty space. We can slide four adjacent (left, right, above and below) tiles into the empty space
How to find if given state is sol... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n03 Nov, 2021"
},
{
"code": null,
"e": 326,
"s": 52,
"text": "What is 8 puzzle? Given a 3×3 board with 8 tiles (every tile has one number from 1 to 8) and one empty space. The objective is to place the numbers on tiles in order using th... |
Python 3 - List len() Method | The len() method returns the number of elements in the list.
Following is the syntax for len() method −
len(list)
list − This is a list for which number of elements to be counted.
This method returns the number of elements in the list.
The following example shows the usage of len() method.
#!/usr/bin/python3
list1 = ... | [
{
"code": null,
"e": 2535,
"s": 2474,
"text": "The len() method returns the number of elements in the list."
},
{
"code": null,
"e": 2578,
"s": 2535,
"text": "Following is the syntax for len() method −"
},
{
"code": null,
"e": 2589,
"s": 2578,
"text": "len(lis... |
Modulo of a large Binary String | 10 May, 2021
Given a large binary string str and an integer K, the task is to find the value of str % K.Examples:
Input: str = “1101”, K = 45 Output: 13 decimal(1101) % 45 = 13 % 45 = 13Input: str = “11010101”, K = 112 Output: 101 decimal(11010101) % 112 = 213 % 112 = 101
Approach: It is known that (str % K) wher... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n10 May, 2021"
},
{
"code": null,
"e": 157,
"s": 54,
"text": "Given a large binary string str and an integer K, the task is to find the value of str % K.Examples: "
},
{
"code": null,
"e": 318,
"s": 157,
"text": "In... |
PostgreSQL – Loading a Database | 20 Sep, 2021
In this article we will look into the process of loading a PostgreSQL database into the PostgreSQL database server. Before moving forward we just need to make sure of two things:
PostgreSQL database server is installed on your system.
A sample database.
For the purpose of this article, we will be using ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n20 Sep, 2021"
},
{
"code": null,
"e": 208,
"s": 28,
"text": "In this article we will look into the process of loading a PostgreSQL database into the PostgreSQL database server. Before moving forward we just need to make sure of two thin... |
Implementation of Queue in Javascript | 18 Feb, 2019
In This article, we would be implementing Queue data structure in javascript. A Queue works on the FIFO(First in First Out) principle. Hence, it performs two basic operations that is addition of elements at the end of the queue and removal of elements from the front of the queue. Like Stack, Queue is also ... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n18 Feb, 2019"
},
{
"code": null,
"e": 384,
"s": 52,
"text": "In This article, we would be implementing Queue data structure in javascript. A Queue works on the FIFO(First in First Out) principle. Hence, it performs two basic operations... |
Program to find the Area of a Parallelogram | 20 Jun, 2022
Given the sides of a Parallelogram, task is calculate the area of a Parallelogram.
Examples:
Input: base = 30, height = 40
Output: 1200.000000
As Area of parallelogram = base * height,
Therefore, Area = 30 * 40 = 1200.00
Approach:
Area of parallelogram = base * height
Below is the implementatio... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n20 Jun, 2022"
},
{
"code": null,
"e": 112,
"s": 28,
"text": "Given the sides of a Parallelogram, task is calculate the area of a Parallelogram. "
},
{
"code": null,
"e": 124,
"s": 112,
"text": "Examples: "
},
{
... |
PostgreSQL – POSITION Function | 01 Feb, 2021
The PostgreSQL POSITION() function returns the location of a substring in a string.
Syntax: POSITION(substring in string)
Let’s analyze the above syntax:
The substring argument is the string that is to be located.
The string argument represents the string for which the substring is to be searched.
The POSI... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n01 Feb, 2021"
},
{
"code": null,
"e": 112,
"s": 28,
"text": "The PostgreSQL POSITION() function returns the location of a substring in a string."
},
{
"code": null,
"e": 150,
"s": 112,
"text": "Syntax: POSITION(subst... |
Recursive program to replace all occurrences of pi with 3.14 in a given string | 17 Dec, 2021
Given string str of size N. The task is to write a recursive function to replace all occurrences of pi with 3.14 in the given string and print the modified string.
Examples:
Input : str = “pippppiiiipi” Output : 3.14ppp3.14iii3.14
Input : str = “pip” Output : 3.14p
Input : str = “xpix” Output : x3.14x
We ... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n17 Dec, 2021"
},
{
"code": null,
"e": 216,
"s": 52,
"text": "Given string str of size N. The task is to write a recursive function to replace all occurrences of pi with 3.14 in the given string and print the modified string."
},
{
... |
Delete Duplicates in MS SQL Server | 08 Sep, 2020
Duplicate values in any table might be due to the poor table design or unwanted data from other sources. To delete the duplicate data from the table in SQL Server, follow the below steps –
Find duplicate rows.Use DELETE statement to remove the duplicate rows.
Find duplicate rows.
Use DELETE statement to re... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n08 Sep, 2020"
},
{
"code": null,
"e": 217,
"s": 28,
"text": "Duplicate values in any table might be due to the poor table design or unwanted data from other sources. To delete the duplicate data from the table in SQL Server, follow the ... |
Pangram Strings | Practice | GeeksforGeeks | Check if the given string S is a Panagram or not. A pangram is a sentence containing every letter in the English Alphabet.
Example 1:
Input: S = "Pack mY box witH fIve dozen
liquor jugs"
Output: 1
Explanation: Given string contains all
English Alphabets.
Example 2:
Input: S = "geeksFORgeeks"
Output: 0
Ex... | [
{
"code": null,
"e": 361,
"s": 238,
"text": "Check if the given string S is a Panagram or not. A pangram is a sentence containing every letter in the English Alphabet."
},
{
"code": null,
"e": 372,
"s": 361,
"text": "Example 1:"
},
{
"code": null,
"e": 508,
"s": 3... |
Spark SQL - JSON Datasets | Spark SQL can automatically capture the schema of a JSON dataset and load it as a DataFrame. This conversion can be done using SQLContext.read.json() on either an RDD of String or a JSON file.
Spark SQL provides an option for querying JSON data along with auto-capturing of JSON schemas for both reading and writing data... | [
{
"code": null,
"e": 1913,
"s": 1720,
"text": "Spark SQL can automatically capture the schema of a JSON dataset and load it as a DataFrame. This conversion can be done using SQLContext.read.json() on either an RDD of String or a JSON file."
},
{
"code": null,
"e": 2182,
"s": 1913,
... |
Interactive COVID-19 visualizations using Plotly with 4 lines of code | by Priya Dwivedi | Towards Data Science | In this age of technology, data is the new oil. Organizations all over the world are transforming their environments, processes and infrastructures to become more data-driven. A major reason is that data analytics and machine learning gives organizations visibility into how to run their business better. The push to rem... | [
{
"code": null,
"e": 574,
"s": 172,
"text": "In this age of technology, data is the new oil. Organizations all over the world are transforming their environments, processes and infrastructures to become more data-driven. A major reason is that data analytics and machine learning gives organizations ... |
How to get the javascript function parameter names/values dynamically? - GeeksforGeeks | 27 Sep, 2021
Given any arbitrary JavaScript function and the task is to return the parameter names of the function.
Approach: JavaScript contains a method called Function.toString() which is used to represent a function code into its string representation. This method is used to get the parameter names/values.
First,... | [
{
"code": null,
"e": 37579,
"s": 37551,
"text": "\n27 Sep, 2021"
},
{
"code": null,
"e": 37683,
"s": 37579,
"text": "Given any arbitrary JavaScript function and the task is to return the parameter names of the function. "
},
{
"code": null,
"e": 37880,
"s": 37683,... |
Select column names containing a string in MySQL? | For this, you can use SHOW COLUMNS command. Following is the syntax. Here, we have set the string using LIKE −
SHOW COLUMNS FROM yourTableName LIKE ‘yourStringValue’;
Let us first create a table −
mysql> create table DemoTable
-> (
-> Id int NOT NULL AUTO_INCREMENT PRIMARY KEY,
-> FirstName varchar(20),
-> ... | [
{
"code": null,
"e": 1173,
"s": 1062,
"text": "For this, you can use SHOW COLUMNS command. Following is the syntax. Here, we have set the string using LIKE −"
},
{
"code": null,
"e": 1229,
"s": 1173,
"text": "SHOW COLUMNS FROM yourTableName LIKE ‘yourStringValue’;"
},
{
"... |
Tree and Level | Practice | GeeksforGeeks | Given a tree with N nodes rooted at 1. Each node labeled with a value arr[i]. The task is to find the absolute difference between the sum of values of nodes at even level and odd level
Note: All the nodes are numbered from 1 to N.
Input:
1. The first line of the input contains a single integer T denoting the number... | [
{
"code": null,
"e": 459,
"s": 226,
"text": "Given a tree with N nodes rooted at 1. Each node labeled with a value arr[i]. The task is to find the absolute difference between the sum of values of nodes at even level and odd level\n\nNote: All the nodes are numbered from 1 to N. "
},
{
"code"... |
How to create a thread in Java | A thread can be created by implementing the Runnable interface and overriding the run() method. Then a Thread object can be created and the start() method called.
The Main thread in Java is the one that begins executing when the program starts. All the child threads are spawned from the Main thread and it is the last t... | [
{
"code": null,
"e": 1225,
"s": 1062,
"text": "A thread can be created by implementing the Runnable interface and overriding the run() method. Then a Thread object can be created and the start() method called."
},
{
"code": null,
"e": 1409,
"s": 1225,
"text": "The Main thread in ... |
How to generate 6-digit random number in MySQL? | You can use LPAD() along with rand() and floor() to generate 6-digit random number. Let us first create a table −
mysql> create table DemoTable
(
Value int
);
Query OK, 0 rows affected (0.64 sec)
Insert records in the table using insert command −
mysql> insert into DemoTable values(1);
Query OK, 1 row affected... | [
{
"code": null,
"e": 1176,
"s": 1062,
"text": "You can use LPAD() along with rand() and floor() to generate 6-digit random number. Let us first create a table −"
},
{
"code": null,
"e": 1267,
"s": 1176,
"text": "mysql> create table DemoTable\n (\n Value int\n );\nQuery OK, ... |
Java & MySQL - Batch Processing | Batch Processing allows you to group related SQL statements into a batch and submit them with one call to the database.
When you send several SQL statements to the database at once, you reduce the amount of communication overhead, thereby improving performance.
JDBC drivers are not required to support this feature. You... | [
{
"code": null,
"e": 2806,
"s": 2686,
"text": "Batch Processing allows you to group related SQL statements into a batch and submit them with one call to the database."
},
{
"code": null,
"e": 2948,
"s": 2806,
"text": "When you send several SQL statements to the database at once, ... |
6 Weeks of Android App Development - FREE Project Based Learning - GeeksforGeeks | 18 Feb, 2022
Are you among the ones who want to learn Android App Development from the beginning? Are you someone who doesn’t have any idea about Android App Development? Or you have just started your journey, but you don’t know whether you are on the right path or not. So, during your initial journey, all you need is ... | [
{
"code": null,
"e": 24728,
"s": 24700,
"text": "\n18 Feb, 2022"
},
{
"code": null,
"e": 25453,
"s": 24728,
"text": "Are you among the ones who want to learn Android App Development from the beginning? Are you someone who doesn’t have any idea about Android App Development? Or yo... |
JavaScript Bubble sort for objects in an array | Suppose, we have a constructor class that creates Shoe objects like this −
class Shoe {
constructor(name, price, type) {
this.name = name;
this.price = price;
this.type = type;
}
};
We are using this class to fill an array with objects like this −
const arr = [
new Shoe('Nike AirMax 90', '120... | [
{
"code": null,
"e": 1137,
"s": 1062,
"text": "Suppose, we have a constructor class that creates Shoe objects like this −"
},
{
"code": null,
"e": 1268,
"s": 1137,
"text": "class Shoe {\n constructor(name, price, type) {\n this.name = name;\n this.price = price;\n ... |
Decision Trees Explained. Learn everything about Decision Trees... | by z_ai | Towards Data Science | In this post, I will explain Decision Trees in simple terms. It could be considered a Decision Trees for dummies post, however, I’ve never really liked that expression.
Before we start, here you have some additional resources to skyrocket your Machine Learning career
Awesome Machine Learning Resources:- For learning re... | [
{
"code": null,
"e": 340,
"s": 171,
"text": "In this post, I will explain Decision Trees in simple terms. It could be considered a Decision Trees for dummies post, however, I’ve never really liked that expression."
},
{
"code": null,
"e": 439,
"s": 340,
"text": "Before we start, ... |
Python Pandas - Comparison with SQL | Since many potential Pandas users have some familiarity with SQL, this page is meant to provide some examples of how various SQL operations can be performed using pandas.
import pandas as pd
url = 'https://raw.github.com/pandasdev/
pandas/master/pandas/tests/data/tips.csv'
tips=pd.read_csv(url)
print tips.head()
Its ... | [
{
"code": null,
"e": 2614,
"s": 2443,
"text": "Since many potential Pandas users have some familiarity with SQL, this page is meant to provide some examples of how various SQL operations can be performed using pandas."
},
{
"code": null,
"e": 2759,
"s": 2614,
"text": "import pand... |
How to click camera programmatically in android? | This example demonstrates how do I click camera programmatically in android.
Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 − Add the following code to res/layout/activity_main.xml.
<?xml version="1.0" encoding="utf-8"?>
<LinearLay... | [
{
"code": null,
"e": 1139,
"s": 1062,
"text": "This example demonstrates how do I click camera programmatically in android."
},
{
"code": null,
"e": 1268,
"s": 1139,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details t... |
Customize Django Admin Interface - GeeksforGeeks | 06 Mar, 2020
Django admin by default is highly responsive GUI, which offers various features and an overall CRUD application to help developers and users. Moreover, Django admin can be customized to fulfill one’s needs such as showing fields on the home page of the table, etc. In this article, we will discuss how to en... | [
{
"code": null,
"e": 25883,
"s": 25855,
"text": "\n06 Mar, 2020"
},
{
"code": null,
"e": 26220,
"s": 25883,
"text": "Django admin by default is highly responsive GUI, which offers various features and an overall CRUD application to help developers and users. Moreover, Django admi... |
Create a vignette filter using Python - OpenCV - GeeksforGeeks | 27 Dec, 2021
In general, Images in computers are stored in the form of a matrix. In case of color image, Image is represented in the form of 3-dimensional matrix or one can say that we use three 2d matrices for representing three color channels one 2d matrix for representing red channel, one for green and one for repre... | [
{
"code": null,
"e": 24579,
"s": 24551,
"text": "\n27 Dec, 2021"
},
{
"code": null,
"e": 25021,
"s": 24579,
"text": "In general, Images in computers are stored in the form of a matrix. In case of color image, Image is represented in the form of 3-dimensional matrix or one can say... |
C++ program to check whether a String is a Pangram or not - GeeksforGeeks | 30 Jul, 2020
Given string str, the task is to check whether a string is pangram or not using in C++.
A string is a Pangram if the string contains all the English alphabet letters.
Examples:
Input: str = “We promptly judged antique ivory buckles for the next prize”Output: YesExplanations: In the above string, str has a... | [
{
"code": null,
"e": 23810,
"s": 23782,
"text": "\n30 Jul, 2020"
},
{
"code": null,
"e": 23898,
"s": 23810,
"text": "Given string str, the task is to check whether a string is pangram or not using in C++."
},
{
"code": null,
"e": 23977,
"s": 23898,
"text": "A ... |
Suppress Warnings Globally in R - GeeksforGeeks | 31 Aug, 2021
In this article, we are going to discuss how to suppress warnings globally in R programming language.
A warning is a message that does not disturb the program flow but displays the warning along with the output. In order to suppress the warnings globally, we have to set warn=-1 in the options function
Synt... | [
{
"code": null,
"e": 24851,
"s": 24823,
"text": "\n31 Aug, 2021"
},
{
"code": null,
"e": 24953,
"s": 24851,
"text": "In this article, we are going to discuss how to suppress warnings globally in R programming language."
},
{
"code": null,
"e": 25154,
"s": 24953,
... |
Tryit Editor v3.7 - Show Java | public class Main {
public static void main(String[] args) {
int myNum = 5; // integer (whole number)
float myFloatNum = 5.99f; // floating point number
char myLetter = 'D'; // character
boolean myBool = true; // boolean
String myText = "Hello"; // String | [] |
Space Science with Python #1 - Setup and first steps | Towards Data Science | Space Science with Python. It may sound challenging, complex and broad. During my time in the university, I got some experience in different Space Science related fields that I linked to data science and machine learning methods. With this part #1 of my tutorial series, I would like to share my experience and knowledge... | [
{
"code": null,
"e": 482,
"s": 47,
"text": "Space Science with Python. It may sound challenging, complex and broad. During my time in the university, I got some experience in different Space Science related fields that I linked to data science and machine learning methods. With this part #1 of my tu... |
Perl - Packages and Modules | The package statement switches the current naming context to a specified namespace (symbol table). Thus −
A package is a collection of code which lives in its own namespace.
A package is a collection of code which lives in its own namespace.
A namespace is a named collection of unique variable names (also called a symb... | [
{
"code": null,
"e": 2326,
"s": 2220,
"text": "The package statement switches the current naming context to a specified namespace (symbol table). Thus −"
},
{
"code": null,
"e": 2394,
"s": 2326,
"text": "A package is a collection of code which lives in its own namespace."
},
... |
Convert CSV to JSON using the Jackson library in Java?
| A Jackson is a Java JSON API that provides several different ways to work with JSON. We can convert CSV data to JSON data using the CsvMapper class, it is specialized ObjectMapper, with extended functionality to produce CsvSchema instances out of POJOs. We can use the reader() method for constructing ObjectReader with ... | [
{
"code": null,
"e": 1494,
"s": 1062,
"text": "A Jackson is a Java JSON API that provides several different ways to work with JSON. We can convert CSV data to JSON data using the CsvMapper class, it is specialized ObjectMapper, with extended functionality to produce CsvSchema instances out of POJOs.... |
HiveQL - Select-Where | The Hive Query Language (HiveQL) is a query language for Hive to process and analyze structured data in a Metastore. This chapter explains how to use the SELECT statement with WHERE clause.
SELECT statement is used to retrieve the data from a table. WHERE clause works similar to a condition. It filters the data using t... | [
{
"code": null,
"e": 2140,
"s": 1950,
"text": "The Hive Query Language (HiveQL) is a query language for Hive to process and analyze structured data in a Metastore. This chapter explains how to use the SELECT statement with WHERE clause."
},
{
"code": null,
"e": 2404,
"s": 2140,
"... |
HTML5 - Audio & Video | HTML5 features include native audio and video support without the need for Flash.
The HTML5 <audio> and <video> tags make it simple to add media to a website. You need to set src attribute to identify the media source and include a controls attribute so the user can play and pause the media.
Here is the simplest form o... | [
{
"code": null,
"e": 2690,
"s": 2608,
"text": "HTML5 features include native audio and video support without the need for Flash."
},
{
"code": null,
"e": 2901,
"s": 2690,
"text": "The HTML5 <audio> and <video> tags make it simple to add media to a website. You need to set src att... |
Introducing SHAP Decision Plots. Visualize the inner workings of machine... | by Floid Gilbert | Towards Data Science | The SHAP (SHapley Additive exPlanations) framework has proved to be an important advancement in the field of machine learning model interpretation. Developed by Scott Lundberg and Su-In Lee, SHAP combines several existing methods to create an intuitive, theoretically-sound approach to explain predictions for any model.... | [
{
"code": null,
"e": 367,
"s": 46,
"text": "The SHAP (SHapley Additive exPlanations) framework has proved to be an important advancement in the field of machine learning model interpretation. Developed by Scott Lundberg and Su-In Lee, SHAP combines several existing methods to create an intuitive, th... |
How to store the contents of arrays in a file using Java? | You can use write data into a file using the Writer classes. In the example given below, we are writing the contents of the array using the BufferedWriter.
Live Demo
import java.io.BufferedWriter;
import java.io.FileWriter;
public class WritingStringArrayToFile {
public static void main(String args[]) throws Except... | [
{
"code": null,
"e": 1218,
"s": 1062,
"text": "You can use write data into a file using the Writer classes. In the example given below, we are writing the contents of the array using the BufferedWriter."
},
{
"code": null,
"e": 1228,
"s": 1218,
"text": "Live Demo"
},
{
"c... |
Erosion and Dilation of images using OpenCV in python - GeeksforGeeks | 25 Jun, 2021
Morphological operations are a set of operations that process images based on shapes. They apply a structuring element to an input image and generate an output image. The most basic morphological operations are two: Erosion and Dilation Basics of Erosion:
Erodes away the boundaries of the foreground obje... | [
{
"code": null,
"e": 41161,
"s": 41133,
"text": "\n25 Jun, 2021"
},
{
"code": null,
"e": 41419,
"s": 41161,
"text": "Morphological operations are a set of operations that process images based on shapes. They apply a structuring element to an input image and generate an output ima... |
GATE | GATE-CS-2003 | Question 80 - GeeksforGeeks | 27 Oct, 2021
Suppose we want to synchronize two concurrent processes P and Q using binary semaphores S and T. The code for the processes P and Q is shown below.
Process P:
while (1) {
W:
print '0';
print '0';
X:
}
Process Q:
while (1) {
Y:
print '1';
print '1';
Z:
}
Synchronization statements can be inser... | [
{
"code": null,
"e": 24594,
"s": 24566,
"text": "\n27 Oct, 2021"
},
{
"code": null,
"e": 24742,
"s": 24594,
"text": "Suppose we want to synchronize two concurrent processes P and Q using binary semaphores S and T. The code for the processes P and Q is shown below."
},
{
"... |
Working With Android WorkManager Using Kotlin | by Himanshu Verma | Towards Data Science | The WorkManager is an API which can schedule your future asynchronous tasks and can run them in the background. The tasks assigned to the WorkManager are executed even if the user is outside the app or app is closed. WorkManager can run your task(s) for one time only as well as many times or periodically.
It provides b... | [
{
"code": null,
"e": 479,
"s": 172,
"text": "The WorkManager is an API which can schedule your future asynchronous tasks and can run them in the background. The tasks assigned to the WorkManager are executed even if the user is outside the app or app is closed. WorkManager can run your task(s) for o... |
Additive Secret Sharing and Share Proactivization - Using Python - GeeksforGeeks | 16 Jul, 2021
A Secret Sharing Scheme is a Cryptographic Scheme that involves the breaking up of a secret value into multiple fragments/shares in a manner that prevents a single shareholder from having complete knowledge of the original secret. Thus, the secret is divided into multiple shares and distributed among multi... | [
{
"code": null,
"e": 24510,
"s": 24482,
"text": "\n16 Jul, 2021"
},
{
"code": null,
"e": 25373,
"s": 24510,
"text": "A Secret Sharing Scheme is a Cryptographic Scheme that involves the breaking up of a secret value into multiple fragments/shares in a manner that prevents a single... |
Visualizing spatial data with geojson heatmaps | by Jan Majewski | Towards Data Science | Have you ever worked with spatial data and faced the challenge of having to choose between overcrowded scatter plots or choropleth maps limited to administrative boundaries such as districts?
Working as a data scientist in the real estate industry, I often deal with spatial data, however, I was struggling to find the o... | [
{
"code": null,
"e": 364,
"s": 172,
"text": "Have you ever worked with spatial data and faced the challenge of having to choose between overcrowded scatter plots or choropleth maps limited to administrative boundaries such as districts?"
},
{
"code": null,
"e": 616,
"s": 364,
"te... |
Data visualization with R and ggplot2 - GeeksforGeeks | 07 Dec, 2021
ggplot2 package in R Programming Language also termed as Grammar of Graphics is a free, open-source, and easy-to-use visualization package widely used in R. It is the most powerful visualization package written by Hadley Wickham.
It includes several layers on which it is governed. The layers are as follows... | [
{
"code": null,
"e": 28964,
"s": 28936,
"text": "\n07 Dec, 2021"
},
{
"code": null,
"e": 29194,
"s": 28964,
"text": "ggplot2 package in R Programming Language also termed as Grammar of Graphics is a free, open-source, and easy-to-use visualization package widely used in R. It is ... |
Hash Function for String data in C# - GeeksforGeeks | 01 Feb, 2019
Question: Write code in C# to Hash an array of keys and display them with their hash code.
Answer: Hashtable is a widely used data structure to store values (i.e. keys) indexed with their hash code. Hash code is the result of the hash function and is used as the value of the index for storing a key. If two... | [
{
"code": null,
"e": 26183,
"s": 26155,
"text": "\n01 Feb, 2019"
},
{
"code": null,
"e": 26274,
"s": 26183,
"text": "Question: Write code in C# to Hash an array of keys and display them with their hash code."
},
{
"code": null,
"e": 26611,
"s": 26274,
"text": ... |
How to check if PSCustomObject is empty in PowerShell? | To check if the PSCustomObject is empty or not in PowerShell, we need to check the fields of the PSCustomObject. Consider the below example,
$output = [PSCustomObject]@{
Name = 'John'
City = 'New York'
Country = 'US'
Company = 'Alpha'
}
$output1 = [PSCustomObject]@{
Name = ''
City = ''
Country = ... | [
{
"code": null,
"e": 1203,
"s": 1062,
"text": "To check if the PSCustomObject is empty or not in PowerShell, we need to check the fields of the PSCustomObject. Consider the below example,"
},
{
"code": null,
"e": 1403,
"s": 1203,
"text": "$output = [PSCustomObject]@{\n Name = '... |
Output of C Program | Set 28 - GeeksforGeeks | 27 Dec, 2016
Predict the output of following C program.
Question 1
#include <stdio.h> int main(){ char a = 30; char b = 40; char c = 10; char d = (a * b) / c; printf ("%d ", d); return 0;}
At first look, the expression (a*b)/c seems to cause arithmetic overflow because signed characters can have va... | [
{
"code": null,
"e": 24250,
"s": 24222,
"text": "\n27 Dec, 2016"
},
{
"code": null,
"e": 24293,
"s": 24250,
"text": "Predict the output of following C program."
},
{
"code": null,
"e": 24304,
"s": 24293,
"text": "Question 1"
},
{
"code": "#include <std... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.