teleren/devto huggingface dataset:
Exploratory Data Analysis using Data Visualization Techniques
Tags: lux, dsea, datascience, data
Published: 2023-10-08 08:29:28

Exploratory Data Analysis involves initial investigation and examination of datasets to summarize the main characteristics often with the help of graphical representations. 
Basically, EDA helps you get a feel of the data you are working with. This is by identifying the structure and patterns involved. EDA helps generate hypotheses about relationships and trends in data which guide further analysis.
EDA with data visualization involves creating various plots and charts, such as **histograms**, **box plots**, **scatter plots**, **bar charts** and **heatmaps**, to visualize the distribution and relationship within the data. With this, you are able to uncover styles, pick out relationships, and gain insights. In case of anomalies, you also get to identify them.
Mostly **Matplotlib** and **Seaborn** are **Python** libraries used for visualization. There exist various sorts of EDA strategies hired depending on the nature of records and desires of evaluation. This includes:

1. **Univariate analysis**-makes a specialty of analyzing character variables inside the records set. It involves visualizing an unmarried variable at a time to understand its distribution. 
Examples include:
   **Histogram** -displays distribution of a single numerical variable. Useful for understanding data's central tendency.
2. **Bivariate analysis**- from the name bi which means two, you explore two variables by finding their correlation, association and dependencies.
 Examples include:
    **Scatter plot** - which explores relationship between two variables.
3. **Multivariate analysis**- extends bivariate evaluation to encompass greater variables. It ambitions to apprehend the complex interactions and dependencies among the many variables in a record set.

More different plots which are also considered as techniques include:

- **Box plots (Box and Whisker)** which provides a summary of visual distribution of data. Good for identifying outliers.

- **Line plots** used for time-series data. They show how a variable change over time identifying trends.

- **Bar charts** mainly used for comparison of categorical data.

- **Heatmaps** which visualize correlation matrix of numerical variables. They use color intensity to represent the strength of correlations.

- **Pie charts** which shows the composition of categorical variable.
Many others include: **pair plots**, **violin plots**, **density plots**, **word cloud** ...

All these visualization techniques can be done in both **Python**, and other visualization tools such as **Excel**, **PowerBi** and **Tableau**. Choice of a tools depends on the user's and interest and what they would like to achieve. 

Therefore, EDA through visualization is a key step in the data analysis process that helps leverage insight into data understanding that results to appropriate business decision making.


_It's Data Allday Everyday_
Resolves error when using image selenium/standalone-chromium with Capybara (Rails)
Tags: webdev, docker, rails
Published: 2023-10-08 08:01:33

When trying to use the selenium/standalone-chrome image with rails I got a very annoying error and the cause is still unknown. But it was resolved by replacing it with another image.

Here is what happened.

## Environment

```yaml
# docker-compose.yml

version: '3.9'
services:
  web:
    # ...
  db:
    # ...
  webdriver_chrome:
    image: selenium/standalone-chromium:117.0
    ports:
      - 4444:4444
      - 5900:5900
```

```ruby
# spec/support/capybara.rb

Capybara.register_driver :remote_chrome do |app|
  options = Selenium::WebDriver::Chrome::Options.new
  options.add_argument('--headless')
  options.add_argument('--no-sandbox')
  options.add_argument('--disable-dev-shm-usage')
  options.add_argument('--window-size=1400,1400')

  Capybara::Selenium::Driver.new(
    app,
    browser: :remote,
    url: ENV['SELENIUM_REMOTE_HOST'],
    options:
  )
end

RSpec.configure do |config|
  config.before(:each, type: :system) do
    driven_by :rack_test
  end

  config.before(:each, type: :system, js: true) do
    if ENV['SELENIUM_REMOTE_HOST'].present?
      Capybara.server_host = IPSocket.getaddress(Socket.gethostname)
      Capybara.app_host = "http://#{Capybara.server_host}"
      driven_by :remote_chrome
    else
      driven_by :selenium_chrome_headless
    end
  end
end
```


## Errors

```
      Selenium::WebDriver::Error::SessionNotCreatedError:
        Could not start a new session. Error while creating session with the driver service. Stopping driver service: Could not start a new session. Response code 500. Message: unknown error: Chrome failed to start: crashed.
          (chrome not reachable)
          (The process started from chrome location /usr/bin/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)

```


## How to temporarily fix it!

Replacing `selenium/standalone-chromium:117.0` with `seleniarm/standalone-chromium:117.0`

```diff
-    image: selenium/standalone-chromium:117.0
+    image: seleniarm/standalone-chromium:117.0
```
Weekly reading digest #8
Tags: php, symfony, backend, softwareengineering
Published: 2023-10-08 08:00:00

[Using Encryption and Authentication Correctly (for PHP developers)](https://paragonie.com/blog/2015/05/using-encryption-and-authentication-correctly)

[Ensuring a Well-Structured Switch Command in PHP](https://www.exakat.io/en/well-structured-switch-command-in-php/)

[Postgres: a Better Message Queue than Kafka?](https://dagster.io/blog/skip-kafka-use-postgres-message-queue)

[MySQL EXPLAIN Explained](https://explainmysql.com/)

[How to Produce a Rich Domain Model with Active Record](https://kevinsmith.io/how-to-produce-a-rich-domain-model-with-active-record/)
Join Hacktoberfest with Swetify-Music
Tags: hacktoberfest, hacktoberfest23, opensource
Published: 2023-10-08 07:56:33

🚀 Exciting News for Open-Source Enthusiasts! 🚀

Hey everyone! 👋 This Hacktoberfest, I'm thrilled to announce that I'm opening up my project, 𝐒𝐰𝐞𝐭𝐢𝐟𝐲-𝐌𝐮𝐬𝐢𝐜, to the open-source community. 🎶

🌟 **What is Hacktoberfest ?**
[Hacktoberfest](https://hacktoberfest.com/) is a month-long celebration of open source, where developers from all around the world come together to contribute to open-source projects. It's the perfect opportunity for beginners to dive into software development and collaborate on meaningful projects. 🙌

Often, people ask me, "Where did you start your open-source journey?" and my answer has always been Hacktoberfest. 💙

Swetify-Music holds a special place in my heart because it's where I began my journey into web development three years ago. Now, I want to invite all of you, especially beginners, to join me in taking this project to new heights! 🌐

🌟 **Why Contribute to Swetify-Music?**
Swetify-Music is a beginner-friendly project that I built when I was learning the fundamentals of web development. If you search precisely, you'll find numerous bugs, opportunities for improvements, and exciting features to work on and contribute to open-source during this Hacktoberfest. Take your first step towards mastering web technologies and contributing to this real-world project. 💡

**GitHub Repo**: [https://github.com/ShwetKhatri2001/Swetify-Music](https://github.com/ShwetKhatri2001/Swetify-Music)
**Tech Stack**: HTML, CSS, Javascript, jQuery

Join in and contribute to making Swetify-Music even more awesome!
Feel free to reach out with any questions or ideas. Let's code, learn, and make this open-source journey an incredible experience for everyone this Hacktoberfest. 🌱
How to turn on charge only mode programatically if the mode if file transfer in android?
Published: 2023-10-08 07:20:23

I will have to show this type of dialog if my device is connected to usb and I want to access the app. Here this dialog shows -Click to Charge Only will automatically set the USB protocol to Charge only mode and i can not access files from my phone

Can Anyone help me to achieve this feature?
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dmm578cfldl142q6v4hy.jpeg)

I have used to get device list but device list is empty. But still i dont thing this will solve my problem

```
for (entry in usbDeviceList.entries) {
            val usbDevice = entry.value

            // Check the USB device's connection mode
            val usbConfiguration = usbDevice.getConfiguration(0)
            val usbInterface = usbConfiguration.getInterface(0)
            val usbInterfaceClass = usbInterface.interfaceClass

            // Check if the interface class indicates MTP (Media Transfer Protocol)
            if (usbInterfaceClass == 6) {
                // The device is in MTP mode (File Transfer mode)
                // You can perform file transfer operations here
                Toast.makeText(applicationContext, "(File Transfer mode)", Toast.LENGTH_LONG).show()
            } else {
                // The device is not in MTP mode
                // Handle the mode accordingly
                Toast.makeText(applicationContext, "MTP mode", Toast.LENGTH_LONG).show()
            }
        }
```
Caption This! 🤔💭
Tags: discuss, watercooler
Published: 2023-10-08 07:00:00


Whatcha got under that thinking cap? Perhaps a witty caption for this week's image? Work your magic!

![Feet tattooed with Stay Here](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m5q622wzirb6gcoy1mjx.png)
---

Follow the DEVteam for more online camaraderie!

{% embed [https://dev.to/devteam](https://dev.to/devteam) %}
Interface Segregation Principle in React
Tags: react, typescript, javascript, learning
Published: 2023-10-08 06:01:07

I (Interface Segregation Principle)

> _No code should be forced to depend on methods it does not use_

![Taking out the trash](https://media.tenor.com/d0l4L0FeEsoAAAAC/dont-need-you-angry.gif)

In React, the Interface Segregation Principle (ISP) emphasizes the importance of creating precise and minimal interfaces for components. It encourages developers to design component interfaces that are tailored to specific needs, avoiding unnecessary bloat. 

This approach results in more modular, maintainable, and reusable code, as components become smaller and focused, promoting better readability and scalability in React applications. ISP encourages cleaner, efficient codebases by advocating for lean and specialized component interfaces.

![Modular GIF](https://static.wixstatic.com/media/7090dd_a883e3ce8c434246ad4544c5c41658c6~mv2.gif)

```typescript
const Book = ({ book }) => {
  return (
    <div>
      <img src={book.image} alt="Book image" />
      <p>{book.title}</p>
      <p>{book.author}</p>
    </div>
  );
};
```

We have a book component which only need few data from the book props which are image, title, and author. By giving it book as a props, we end up giving it more than the component actually need because the book props itself might contain data that the component doesn't need

To mitigate this problem we can limit the props to only what the component need.

```typescript
const Book = ({ image, title, author }) => {
  return (
    <div>
      <img src={image} alt="Book image" />
      <p>{title}</p>
      <p>{author}</p>
    </div>
  );
};
```

By doing so, we are applying the ISP principle, thus avoiding clients of our component from depending on an interface they are not using. 

## What's next?

Let's not stop here since there is 1 principle left to learn in SOLID which I will cover in the next article so stay tuned.

Dadah~ 👋
Effects of listening 🎧 to music while coding
Tags: webdev, productivity
Published: 2023-10-08 06:01:00

"Do you listen to music 🎵 while coding?"

I was asked this question recently by a friend of mine.

Well, I do it a lot, even though it is a bad habit.

🤚 Don't get me wrong.

Listening to music 🎶 is great. It can: 

- Improve your mood.
- Help reduce depression.
- And decrease anxiety.

But becomes a problem when you do it too often.

Especially when listening to high-BPM music while doing work that you are required to be deeply immersed in.

This leads to sensory overload, which is the overstimulation of one or more of the body's five senses. 

When our brains 🧠 are constantly bombarded with sensory information or have to process too much complex information, we become overwhelmed and exhausted.

The solution to this?

I recommend listening to Lo-Fi music while working. 

Lo-fi music is a genre that features mellow melodies and calming vibes, making it ideal for creating a relaxing atmosphere while studying and working.

This type of music is often instrumental, with minimal lyrics, which can reduce distractions and help you improve concentration.

Do like 👍 and 🏃 follow for more content.
Why Developers Should Avoid Coffee Shops (and Other Productivity Warzones) ☕
Tags: programming, developer, opensource, beginners
Published: 2023-10-08 05:52:30

As a developer, I have a confession to make: I'm not always productive. 

We've all been there, haven't we? Those moments when productivity goes out the window, and coding becomes an endangered skill. 

Let's take a stroll through the perilous places where developers should never tread unless they want the precious hours to disappear into the void:

## Coffee Shops: The Caffeinated Trap ☕

Coffee shops lure us in with their promise of comfy chairs, free WiFi, and an endless flow of liquid motivation. But let's face it, the moment that steamy latte touches your lips, you're lost in a world of daydreams and Twitter memes. Three hours in, you've not written a single line of code, but you've got grand plans to revolutionize your to-do list organization. Verdict: Coffee shops are productivity black holes.

## Co-working Spaces: The Distraction Abyss

Imagine a coffee shop, but with the added menace of fellow developers trying to focus. It's a productivity deathmatch in there. The guy next to you starts an impassioned debate about the latest JavaScript framework, and another seeks a guru to vanquish a bug that's haunted them for days. By day's end, your codebase is untouched, and you've become a passive member of the distraction Olympics.

## Conference Rooms: The Fishbowl Fiasco 

Picture this: you're in a conference room, trying to code. It's akin to attempting to pen a novel in a fishbowl. Zero privacy, everyone's gawking, and just as you begin typing, someone insists on a "quick chat" about the cutting-edge marketing strategy. No, just no.

## Airplanes: The Turbulent Code Quest 

Long flight ahead? You might think, "Perfect time to code!" But beware, the coding gods have other plans. Turbulence, wailing babies, and a never-ending parade of snack carts are your foes. Did I mention the absence of WiFi? Coding in-flight is like chasing unicorns.

## The Beach: A Sandy Mirage 

This one might puzzle you. The beach, a coding sanctuary? Think again. Sand invades every crevice, the sun blinds your screen, and the noise level is like a rock concert for seagulls. Typing on a sand-coated laptop? It's like playing typographical Twister, a game only for the bravest.

So there you have it, dear developers. To safeguard your coding prowess, steer clear of these productivity minefields. Retreat to your dimly lit basement office or invest in noise-cancelling headphones and a healthy dose of self-discipline. Happy coding, and may your lines of code flow like poetry in the night! 💻🚀😅
How to publish posts to tumblr using tumblr api in express.js
Tags: freecodez, react, html, blog
Published: 2023-10-08 05:48:09

Hey there, You are most welcome to this article. I hope you will enjoy this article. If you like this article then please share this article with your friends and colleagues. If you have any questions or suggestions regarding this article then please comment down below.

**How to publish posts to tumblr using tumblr api in express.js**

![How to publish posts to tumblr using tumblr api in express.js](https://res.cloudinary.com/freecodez/image/upload/v1696744088/images/xbplyidwwr5blhijsgsb.webp)

For full source code visit : [https://freecodez.com/post/2dtp8ng](https://freecodez.com/post/2dtp8ng)


```

```

Source Code : [https://freecodez.com/post/2dtp8ng](https://freecodez.com/post/2dtp8ng)

For more such articles visit : [https://freecodez.com](https://freecodez.com/all)
String in JavaScript
Tags: javascript, beginners, programming
Published: 2023-10-08 05:45:48

### Single and Double Quotes in JavaScript Strings
Strings in JavaScript are contained within a pair of either single quotation marks '' or double quotation marks "". Both quotes represent Strings but be sure to choose one and STICK WITH IT. If you start with a single quote, you need to end with a single quote. There are pros and cons to using both IE single quotes tend to make it easier to write HTML within Javascript as you don’t have to escape the line with a double quote.

```
console.log('This is a string. 👏') 
// output: This is a string. 👏
console.log("This is the 2nd string. 💁"); 
// output: This is the 2nd string. 💁
```
### Enclosing Quotation Marks
Let’s say you’re trying to use quotation marks inside a string. You’ll need to use opposite quotation marks inside and outside of JavaScript single or double quotes. That means strings containing single quotes need to use double quotes and strings containing double quotes need to use single quotes.

```
console.log("It's six o'clock.");
// output: It's six o'clock.
console.log('Remember to say "please" and "thank you."');
// output: Remember to say "please" and "thank you.
```

Alternatively, you can use a backslash \ to escape the quotation marks. This lets JavaScript know in advance that you want to use a special character.

Here’s what that looks like reusing the examples above:

```
console.log('It\'s six o\'clock.');
// output: It's six o'clock.
console.log("Remember to say \"please\" and \"thank you.\"");
// output: Remember to say "please" and "thank you".
```
### String Methods and Properties
Strings have their own built-in variables and functions, also known as properties and methods. Here are some of the most common ones.

#### String Length
A string’s length property keeps track of how many characters it has.

```
// EXAMPLE
console.log("caterpillar".length);
// output: 11
```

#### toLowerCase Method
A string’s toLowerCase method in JavaScript returns a copy of the string with its letters converted to lowercase. Numbers, symbols, and other characters are not affected.

```
console.log("THE KIDS".toLowerCase());
// Example
// output: the kids
```

#### toUpperCase Method
A string’s toUpperCase method returns a copy of the string with its letters converted to capitals. Numbers, symbols, and other characters are not affected.

```
// EXAMPLE
console.log("I wish I were big.".toUpperCase());
// output: I WISH I WERE BIG.
```
#### trim Method
A string’s trim method returns a copy of the string with beginning and ending whitespace characters removed.

```
// EXAMPLE
console.log("   but keep the middle spaces   ".trim());
// output but keep the middle spaces
```
রিডাক্সে মাধ্যমে এরেতে ডাটা পাঠানো ।
Tags: redux, reducer
Published: 2023-10-08 05:32:00

এই খানে দুইটি ওয়ে নিয়ে আলোচনা করবো, একটি immutable ওয়ে আরেকটি হল Mutable ওয়ে ।


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vd3eeo43u6avy6tecls4.png)



**১ম ঊদাহরনঃ**

``addToProduct: (state, action) => {

state.products = [...state.products, action.payload]

}``

এখানে addToProduct নামে একটা ফাংশন নিয়ে এর ভিতর দুইটি প্যারামিটার নেওয়া হয়েছে state এবং action নামে । তারপর Initial state এ যে products ছিলো সেটা কল করে ...state.products  স্প্রেড অপারেটর চালানো হয়েছে । যদি আগে থেকে কোন প্রডাক্ট থাকে তাহলে সে গুলোকে নিয়ে নতুন এরে দেখাও তারপর action.payload থেকে নতুন প্রডাক্ট এড করে দাও।

এই পদ্ধতি হচ্ছে immutable  ওয়ে । এই পদ্ধতির অনেক গুলো ভালো দিক হচ্ছে আগের স্টেত মডিফাই করে না, খুব সহজে ডিভাগ করা যায় এবং কি কি পরিবর্তন হচ্ছে তা বুঝা যায়।


**এখন ২য় উদাহরণ নিয়ে আলোচনা করবোঃ**

``addToProduct: (state, action) => {

state.products.push(action.payload)

}``

এখানে আগের মতো সব কিছু নেওয়া হয়েছে শুধু state.products এর ভিতর action.payload কে পুশ করে দেওয়া হয়েছে । এটা mutated পদ্ধতি । এটা আগের এরেকে চেঞ্জ করে দেয়, এবং কি কি পরিবর্তন হয়েছে তা ট্রেক করা কঠিন হয়ে পরে।

পরিশেষে বলা যায় দুইভাবে আমরা রিডাক্সের এর মাধ্যমে এরেতে কোন কোন কিছু এড করতে পারবো । তবে ভালো প্রেটিক্স হল  immutable ওয়েতে হেন্ডেল করা।



ধন্যবাদ

সেলিম আল সাজু
100 berufliches Vorwärtskommen: Gute Taten in der Restzeit.
Tags: deutsch, career, motivation, discuss
Published: 2023-10-08 05:30:00

Moin Moin,

ich liste einiges auf und würde gerne wissen was du dazu denkst:

- Nachwuchsförderung ( Bildungsangebote, Lehrmeisterschaft ( mentoring ))
- freie Softwareprojekte
- offene Softwareprojekte
- Unterstützung Benachteiligter
- Vereine unterstützen

Interessanterweise können auch Anfänger bspw. durch die Unterstützung von Vereinen, praktische Erfahrung und damit auch Referenzen sammeln.

Was denkst du dazu?

Schlussbemerkung:
gut := [(sittlich) einwandfrei, wertvoll↗](https://www.dwds.de/wb/gut#d-1-5)

Lass uns mittels Kommentaren austauschen.

Beste Grüße,
Mustafa

Oder auch mittels E-Mail: mustafa.kevin.dwenger@posteo.de
Betreff: Austausch
Host Your JSON File in Minutes
Tags: json, storage, hosting, frontend
Published: 2023-10-08 05:25:25

---
title: Host Your JSON File in Minutes
published: true
description: No more backend hassles! JSONsilo.com - where JSON magic happens for quick UI/UX prototyping.
tags: JSON, storage, hosting, frontend
cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0du9poh989ixz77ajvxm.png
# Use a ratio of 100:42 for best results.
# published_at: 2023-08-02 02:13 +0000
---

Greetings! Today, I am excited to introduce you to a powerful tool that can significantly accelerate your development process, particularly if you're a frontend developer. 🎨

Are you a dedicated frontend developer who dislikes dealing with backend development or simply someone who wants to quickly test your UI/UX without the hassle of setting up a real backend? If so, then this tool is perfect for you. Allow me to introduce you to [JSONsilo.com](https://jsonsilo.com)!

JSONsilo.com offers up to 5MB of storage and unlimited requests, setting it apart from other services that impose limits on both requests and storage.

![jsonsilo.com Core Advantages](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4bdl7mkvx2vtg73op08b.png)

But that's not all! JSONsilo.com also allows you to set your JSON files to private, requiring authentication via an API Key before making requests.

![jsonsilo.com private silo](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w0f8hpf5ney3x0rnkr8d.png)

What sets JSONsilo.com apart is its simplicity. You can get started in no time with no extra configuration – simply copy and paste or drag and drop your JSON file. It couldn't be easier!

![jsonsilo.com drag and drop](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/g5cfvzl7vvgjit02dtxv.gif)

JSONsilo offers a free plan that you can use indefinitely, allowing you to create one silo with a 5MB storage capacity, and there's no need for a credit card during registration.

![jsonsilo.com pricing](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a7o28ug1c8148vyix6ff.png)

Additionally, we offer a Pro plan for just $9.99 a month. What are the benefits of going Pro? With the Pro plan, you can create up to 101 silos (with one free) and access advanced caching features.

Don't miss out on this opportunity! [Sign up](https://jsonsilo.com) now and enjoy a 🎁 **30% discount** 🎁 for the **first month** using the discount code: `DEVSILO`.