Git Product home page Git Product logo

-_ts's Introduction

尚硅谷_ts

pandas/numpy echarts python3.8 django drf umi celery socket redis pytest umi react echart antd

https://git-scm.com/book/zh/v2/Git-%E5%88%86%E6%94%AF-%E5%88%86%E6%94%AF%E7%AE%80%E4%BB%8B

vim(command): https://unix.stackexchange.com/questions/115886/anyway-to-navigate-percentage-wise-in-vim 50% will come to log 50% position(no need to access command mode otherwise it will not working)

gg Move to the first line of the file G Move to the last line

20240403

  1. there exists a big dataframe(size(3400000, 8)),i want to get subdataframe by column values

    first solusion

    get unique y name, then get every group data by y name

    y_values = data[v_y_name].unique().tolist() for y_value in y_values:

    one segment data

    segment_data = data[data[v_y_name] == y_value] (34s)

    segment_data = data.loc[data[v_y_name] == y_value] (34s)

    it's too slow then i think why not group by v_y_name then get every group dataframe by name, then i try following code:

    y_groups = data.groupby(v_y_name) y_values = data[v_y_name].unique().tolist() for y_value in y_values:

    much faster

    segment_data = y_groups.get_group(y_value) (0.5s)

    https://www.geeksforgeeks.org/ways-to-filter-pandas-dataframe-by-column-values/

-_ts's People

Contributors

little-zhou avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.