Skip to content

Instantly share code, notes, and snippets.

View Maycol-Rodriguez's full-sized avatar
💻
Focusing

Maycol Rodriguez Maycol-Rodriguez

💻
Focusing
View GitHub Profile
@Maycol-Rodriguez
Maycol-Rodriguez / box-plot
Created December 10, 2025 11:33
crea boxplot para todo tu df
props_outliers = dict(markerfacecolor="blue", marker="D", markersize=6)
X_log.plot(
kind="box",
subplots=True,
layout=(6, 4),
sharex=False,
sharey=False,
figsize=(20, 20),
title="Detección de Outliers por Variable",
@Maycol-Rodriguez
Maycol-Rodriguez / importaciones
Last active October 5, 2025 21:17
importaciones python
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
import statsmodels.api as sm
sns.set(style='white')
@Maycol-Rodriguez
Maycol-Rodriguez / MapGeneral.tsx
Created May 17, 2024 06:29
boilerplate for map create
'use client';
import population from '@/constants/population.constants.json';
import { Department } from '@/interfaces';
import { generateMapColors } from '@/utils/generateMapColors';
export const Map = ({ department, province, handleClick }: Props) => {
};
@Maycol-Rodriguez
Maycol-Rodriguez / hydration.tsx
Created April 12, 2024 06:30
error hydration
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
}, []);
if (!mounted) return null;
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
}, []);
if (!mounted) return null;
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
}, []);
if (!mounted) return null;
@Maycol-Rodriguez
Maycol-Rodriguez / MaterialInput.html
Last active April 11, 2024 04:48
material design input
<div className="mr-auto md:mr-4 md:w-56">
<div className="relative h-10 w-full min-w-[200px]">
<input
className="disabled:bg-blue-gray-50 placeholder-shown:border-blue-gray-200 placeholder-shown:border-t-blue-gray-200 border-blue-gray-200 peer h-full w-full rounded-[7px] border border-t-transparent bg-transparent px-3 py-2.5 font-sans text-sm font-normal text-gray-700 outline outline-0 transition-all placeholder-shown:border focus:border-2 focus:border-blue-500 focus:border-t-transparent focus:outline-0 disabled:border-0"
placeholder=" "
/>
<label className="peer-disabled:peer-placeholder-shown:text-blue-gray-500 before:content[' '] after:content[' '] text-blue-gray-400 before:border-blue-gray-200 after:border-blue-gray-200 pointer-events-none absolute -top-1.5 left-0 flex h-full w-full select-none text-[11px] font-normal leading-tight transition-all before:pointer-events-none before:mr-1 before:mt-[6.5px] before:box-border before:block before:h-1.5 before:w-2.5 before:rounded-tl-md
<Toaster
richColors
duration={2000}
position="top-right"
visibleToasts={4}
toastOptions={{
className: 'rounded-sm',
}}
/>
@Maycol-Rodriguez
Maycol-Rodriguez / .prettierrc
Last active April 3, 2024 16:22
format tailwind class - .prettierrc
//pnpm install -D prettier prettier-plugin-tailwindcss -E
{
"plugins": ["prettier-plugin-tailwindcss"],
"singleQuote": true
}
@Maycol-Rodriguez
Maycol-Rodriguez / vite.config.ts
Last active April 8, 2024 03:47
configuración de imports alias
// vite.config.ts,
// instalar => pnpm install -D @types/node
import react from '@vitejs/plugin-react-swc';
import path from 'path';
import { defineConfig } from 'vite';
export default defineConfig({
plugins: [react()],
resolve: {
alias: {