Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
  • 18:42
    alexreg synchronize #44186
  • 18:00
    jbrockmendel opened #44220
  • 17:49
    Sara-cos commented #43604
  • 17:41
    jbrockmendel synchronize #44212
  • 17:38
    jbrockmendel opened #44219
  • 17:04
    trallard commented #44029
  • 16:43
    trallard edited #44029
  • 16:34
    trallard synchronize #44029
  • 16:32
    topper-123 edited #44218
  • 16:20
    attack68 commented #43894
  • 16:20
    attack68 commented #43894
  • 16:14
    topper-123 labeled #44218
  • 16:01
    trallard synchronize #44029
  • 16:00
    trallard synchronize #44029
  • 15:52
    trallard synchronize #44029
  • 15:49
    jbrockmendel commented #44081
  • 15:46
    trallard synchronize #44029
  • 15:28
    jbrockmendel synchronize #44175
  • 15:28
    jbrockmendel synchronize #44193
  • 15:07
    phofl commented #43943
I believe so. I have updated the master of my cython repository locally. Should I be doing something to build cython? Since the "contributing to pandas" doc mentioned I shouldn't have to do the configure and make steps, I skipped that and just installed the compiler via xcode (which already existed).
I tried reinstalling via xcode post my update of the cython repository.
Marc Garcia
@killerontherun1 can you make sure your copy of the pandas source is updated (i.e. git fetch upstream && git merge upstream/master), and in the root of the project run conda env update if you already have a conda environment, or conda env create if you don't. Then a python setup.py build_ext --inplace --force should work, otherwise there is something weird going on
Hasan Shaukat
I have a dataframe df = pd.DataFrame({'col1':['a', 'b', 'a', 'b', 'c']})
I want to make an 'is_first' column which would have [1,1,0,0,1] (1 if the col1 value appeared for the first time, 0 otherwise)
Any pandorable, vectorized approach for this?
Gareth Elston
Where should I go to report problems with the pandas.pydata.org website?
Gareth Elston
Specifically, https://pandas.pydata.org/pandas-docs/stable/pandas.pdf tells me that "pandas.pydata.org redirected you too many times," gives me an "ERR_TOO_MANY_REDIRECTS" message, and suggests that I "Try clearing your cookies." It tells me the same thing even after I have cleared all my cookies and set the options to allow cookies.
Gareth Elston
Similar messages from Firefox (above was Chrome).
Minho Ryang
Ping, Is there anybody here? My friend @proost is trying to resolve #20519, and needs some help to get a clue. (He chose this issue at PyConKR19 Sprint, and got lost in codes.)
Vishesh Mangla
why its not in a line?
Vishesh Mangla
why isnt it working?
Hello guys, i'm getting error while dataframe.to_parquet(fn,engine='pyarrow')
ImportError: Missing optional dependency 'pyarrow'. pyarrow is required for parquet support. Use pip or conda to install pyarrow.
but i have install pyarrow with pip and conda
still getting error
Vishesh Mangla
How to fix these labels in these?
the last one shows L2 norm
but I want it in one line
@datapythonista : There's something weird going on. To be sure, i reinstalled conda, I've fetched as instructed, and built with the force flag. It built successfully, and to my dismay, when I try to import it the same error as before occurs indicating the c extensions did not get built. I've got the stdout of my build command in a file, which I'd be happy to send across. My python version is Python 3.7.4 (default, Aug 13 2019, 15:17:50) and gcc --version gives me
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/c++/4.2.1 Apple LLVM version 10.0.0 (clang-1000.10.44.4) Target: x86_64-apple-darwin18.2.0 Thread model: posix InstalledDir: /Library/Developer/CommandLineTools/usr/bin.
@HasanShaukat Usually better suited for stackoverflow. But you could do this
>>> from pandas import DataFrame as df, concat
>>> tbl = df({'col1':['a', 'b', 'a', 'b', 'c']})
>>> test = concat([tbl,tbl.duplicated().astype(int)],axis=1);test[0] = test[0].apply(lambda x: 1 if x==0 else 0)
>>> test
  col1  0
0    a  1
1    b  1
2    a  0
3    b  0
4    c  1
Arun Persaud
just trying to upgrade pandas for a linux distribution and ran into an issue that some test use for example "subprocess.check_output(["python", "-c", code])..." where python is hardcoded, but for the linux distribution python might be called python3 for example and the test fails... perhaps sys.executable would be better? is this something one should report in the bug tracker or what is the best place to report this?
Tom Augspurger
I htink this is fixed on master @arunpersaud.
Arun Persaud
@TomAugspurger thanks, should have checked there, sorry for the noise...
Kolmar Kafran
What's the difference between df['column'] and df.column?
William Ayd
Usually nothing but the former is the preferred / suggested approach
Joris Van den Bossche
Kolmar Kafran
ThankYou very much
Hi.. am a beginner and am excited to be here. Blessings , eve
Peter Hull
Hi. Is there a way to select columns from a DataFrameGroupBy?
I wanted to group data once, then select several columns in turn without having to re-do the grouping each time.
df.groupby('x')[['y']] doesn't do what I expected it to.
Asked on SO, but I'm not sure if I'm asking in the right way... https://stackoverflow.com/questions/57629784/select-column-from-groupby-for-boxplot
@datapythonista @TomAugspurger : FYI. Figured out the issue, in case anyone else faces this, it was an env (conda) problem. I did not remove the environment properly. Successfully got the env set up again and it is fixed.
Shubham Sharma
hello, anyone scrapped data from Walmart ???
i want to write a script that will search for a product and then scrap the search result from the website,
My question is that is Walmart allow scripts to scrap data and is anyone done this before
plz, i need help
Florent Piétot
Hello, can anyone point me to source code that handles plotting a bar plot from a dataframe? e.g. when calling df.plot(kind='bar')
Florent Piétot
Johannes Wienke
Hi, has anyone seen that parquet files generated with the fastparquet backend cannot be read with the pyarrow implementation? pyarrow can read the parquet file but the conversion to pandas data frame seems to be messed up and fails
William Ayd
Does anyone know what our rules for coercing np.datetime64 objects to pd types (Timestamp or NaTType) are?
I found the following somewhat interesting
>>> ser = pd.Series([np.datetime64("2000-01-01")], dtype=object)
>>> type(ser.iloc[0])
>>> type(ser.to_frame().iloc[0, 0])
It seems like a Series can hold np.datetime64 in an object array, but a DataFrame cannot (tried also by constructing the DataFrame directly)
Plots are not appearing in Spyder IDE, but scripts work fine in Jupyter. I did run below scripts in Jupyter and it did work fine. Why don't plots appear in the spyder console? Do these libraries only specific to Jupyter? What should I have to follow to get the scripts in Spyder. Could someone help me with his https://www.biostars.org/p/397000/#397092
Hi, does apply in df.apply(fun) iterate over each columns in 'df' data-frame and pass them to 'fun' function as a series?
Assaf Ben-amitai
hi, does anyone knows if pandas can be instruct to format dataframe prints to use engineering notation (10M, 4G etc)?
William Ayd
@datapythonista or anyone else with knowledge, is there a particular reason why we customize isort to control the placement of pandas.core?
Is it purely a stylistic concern or was it driven out of circular imports