Comments (9)
from pyranges.
I can have a look on Monday. Thanks.
from pyranges.
There is no risk here that the object passed in will be changed.
reindex
creates new objects:
scdf, ocdf = scdf.reindex(_self_indexes), ocdf.reindex(_other_indexes)
from pyranges.
@endrebak thank you for looking into this. So what would be the most appropriate way to get rid of this warning? should I just suppress it?
from pyranges.
I am a bit surprised that it shows up. If you look at the code, you see that I turn off the warning.
from pyranges.
yes I have no idea why its still complaining. what pandas version are you using?
from pyranges.
2.0.1
from pyranges.
@endrebak I see, and do you still get this warning too with the newer pandas version?
from pyranges.
I believe I am seeing this, also, though I'm not sure it is the same FutureWarning.
x = pr.read_gtf('test_gtf.txt')
x.features.introns(by='transcript').intersect(x[x.Feature=='exon'],strandedness='same', how='containment')
result:
Chromosome Source Feature Start End Score Strand Frame gene_id transcript_id
0 chr1 unknown intron 15 19 . + . gene1 transcript_1
1 chr1 unknown intron 15 19 . + . gene1 transcript_1
FutureWarning: The `inplace` parameter in pandas.Categorical.add_categories is deprecated and will be removed in a future version. Removing unused categories will always return a new Categorical object.
introns.Feature.cat.add_categories(["intron"], inplace=True)
FutureWarning: In a future version, `df.iloc[:, i] = newvals` will attempt to set the values inplace instead of always setting a new array. To retain the old behavior, use either `df[df.columns[i]] = newvals` or, if columns are non-unique, `df.isetitem(i, newvals)`
introns.loc[:, "Feature"] = "intron"
pyranges version info:
{'pyranges version': '0.0.120', 'pandas version': '1.5.2', 'numpy version': '1.23.0', 'python version': sys.version_info(major=3, minor=9, micro=18, releaselevel='final', serial=0), 'ncls': '0.0.65', 'sorted_nearest': '0.0.37', 'pyrle': '0.0.35', 'ray': 'not installed', 'bamread': 'not installed', 'pyranges_db': 'not installed', 'pybigwig': 'not installed', 'hypothesis': 'not installed'}
from pyranges.
Related Issues (20)
- Additional how-to-pages HOT 1
- Stable non-conflicting interface: v.1.0.0 HOT 2
- Return overlap between PyRanges objects, keeping columns from both? HOT 6
- subtract does not respect strandedness default
- when using .coverage: AttributeError: module 'numpy' has no attribute 'long' HOT 1
- count_overlaps causes overflow errors when number of reads are large HOT 1
- ModuleNotFoundError: No module named 'pyfaidx' HOT 2
- count_overlaps documentation says it supports nb_cpu but it is not implemented HOT 5
- overlap default strandedness argument incorrectly documented
- pr.get_sequence may not be working? HOT 4
- PyRanges.intersect - "invert=True" kwarg behavior HOT 1
- pyranges.cluster() Exception: Starts/Ends not int64 or int32: int64 HOT 9
- Unexpected behaviour with strandedness of pyranges object HOT 8
- PyRanges read_bed produces wrong number of chromosomes when cast to categorical HOT 1
- ResourceWarning: files opened in readers.read_bed are never closed HOT 3
- SyntaxError: invalid syntax for L131 in names.py HOT 12
- `join` method exits unexpectedly HOT 4
- `np.bool` error in gr.head()
- Add importable constants for Chromosome, Start, End, etc. HOT 2
- Can only do stranded operations when both PyRanges contain strand info HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyranges.