Re: Who are the "spacists"?

2017-03-19 Thread Larry Hudson via Python-list
thing I find annoying about an editor set to expand tabs to spaces is that it takes one keypress to indent but four (or whatever) to unindent. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

How to search out all Zip codes and replace with the first 2 digits, in a Pandas dataframe, with the use of regex?

2017-03-20 Thread David Shi via Python-list
/listinfo/python-list

Re: Escaping confusion with Python 3 + MySQL

2017-03-26 Thread Larry Hudson via Python-list
4', 'cyta.gr') How should i write the cursor.execute in order to be parsed properly? As i have it now %s does not get substituted. You don't get the substitution because you're missing a %. Change: ... LIKE "%s"''', (pID, ... To: ... LIKE "%s"''' % (pID, ... -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

How to make use of .egg files?

2017-04-05 Thread David Shi via Python-list
Can anyone explain please. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread David Shi via Python-list
I tried the following codes: import urllib2response = urllib2.urlopen('http://cordis.europa.eu/search/result_en?q=uk&format=csv')myCSV = response.read() myFile = pd.read_csv(myCSV) but, it did not work well. Can any one help? Regards. David -- https://mail.python.org/mailman/l

Re: How to capture a CSV file and read it into a Pandas Dataframe?

2017-04-05 Thread David Shi via Python-list
there a way to capture the file? Regards. David On Wednesday, 5 April 2017, 17:19, Skip Montanaro wrote: I'm not positive, but try passing response to read_csv() instead of reading the bytes yourself. Skip On Apr 5, 2017 10:38 AM, "David Shi via Python-list" wrote:

[no subject]

2017-04-07 Thread David Shi via Python-list
I was using IPython notebooks.  All the sudden, it asks for password or token. I did not set any password or token. How do I get back to use my IPython notebooks? Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

A Python solution for turning a web page into Pandas DataFrame table

2017-04-07 Thread David Shi via Python-list
Is there a Python solution for turning a web page into Pandas DataFrame table? Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Pound sign problem

2017-04-10 Thread David Shi via Python-list
encode character u'\xa3' in position 0: ordinal not in range(128) Can anyone help? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

XML tree to a pandas dataframe

2017-04-12 Thread David Shi via Python-list
What is the best way to convert XML document into a pandas dataframe? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

How to pd.read_csv into a DataFrame with multiple seperators?

2017-04-12 Thread David Shi via Python-list
Have a look at this example. http://www.ebi.ac.uk/ena/data/warehouse/search?query=%22geo_circ(-0.587,-90.5713,170)%22&result=sequence_release&display=text How to pd.read_csv into a DataFrame with multiple seperators? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Read a text file into a Pandas DataFrame Table

2017-04-13 Thread David Shi via Python-list
Dear All, Can anyone help to read a text file into a Pandas DataFrame Table? Please see the link below. http://www.ebi.ac.uk/ena/data/warehouse/search?query=%22geo_circ(-0.587,-90.5713,170)%22&result=sequence_release&display=text Regards. David -- https://mail.python.org/mailman/listinf

Reading structured text file (non-CSV) into Pandas Dataframe

2017-04-13 Thread David Shi via Python-list
be made? Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

[no subject]

2017-04-13 Thread David Shi via Python-list
13.1. csv — CSV File Reading and Writing — Python 2.7.13 documentation | | | 13.1. csv — CSV File Reading and Writing — Python 2.7.13 documentation | | | I am trying to parse this text file into a table. How to use consecutive 3 spaces to work as delimiter with csv.reader? Looking

[no subject]

2017-04-13 Thread David Shi via Python-list
Which VCF reader has been well tested and proven to be robust? Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

How to do pd.read_csv with consecutive spaces or semi-colon as delimiters?

2017-04-18 Thread David Shi via Python-list
Any way to do that? The link to a sample dataset is as follows: http://www.ebi.ac.uk/ena/data/warehouse/search?query=%22geo_circ(-0.587,-90.5713,170)%22&result=sequence_release&display=text Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinf

Pressing dot and show sub command in IPython

2017-04-18 Thread David Shi via Python-list
/listinfo/python-list

Turtle window not closing

2017-04-21 Thread Harshika Varadhan via Python-list
        t.right(180)     turtle.bye() Thank you, Harshi -- https://mail.python.org/mailman/listinfo/python-list

Re: Turtle window not closing

2017-04-22 Thread Harshika Varadhan via Python-list
n Saturday, April 22, 2017 3:56 AM, Peter Otten <[email protected]> wrote: Harshika Varadhan via Python-list wrote: > I am creating a game where the user inputs a coordinate to place their > piece on a chess board. My code then draws the chess board with a turtle > and fills in

Re: Rosetta: Sequence of non-squares

2017-05-02 Thread Mark Summerfield via Python-list
On Monday, May 1, 2017 at 9:47:10 PM UTC+1, [email protected] wrote: > On Monday, May 1, 2017 at 11:27:01 AM UTC-7, Robert L. wrote: > [no Python] > > Do you ever plan to ask any questions about Python? Or are you just using a > few lines of code as a fig leaf for the race baitin

Install python via MS batch file

2017-05-06 Thread Mahmood Naderan via Python-list
Hello, I have downloaded python-3.6.1-amd64.exe and it is fine to install it through GUI. However, I want to write a batch file to install it via command line. Since the installation process is interactive, it seems that the auto-install batch file is difficult. What I want to do is: set

ANN: distlib 0.2.5 released on PyPI

2017-05-06 Thread Vinay Sajip via Python-list
or in scoring URLs for preferences. * Removed Python 2.6 from the support list. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1]

packaging python code

2017-05-08 Thread Mahmood Naderan via Python-list
Hi, I have simple piece of code which uses two libraries (numpy and openpyxl). The script is called from another application. Currently, if someone wants to run my program, he has to first install the python completely via its installer. Is there any way to pack my .py with all required

Re: packaging python code

2017-05-08 Thread Mahmood Naderan via Python-list
OK. I did that but it fails! Please see the stack D:\ThinkPad\Documents\NetBeansProjects\ExcelTest>pyinstaller exread.py 96 INFO: PyInstaller: 3.2.1 96 INFO: Python: 3.6.1 98 INFO: Platform: Windows-10-10.0.14393-SP0 103 INFO: wrote D:\ThinkPad\Documents\NetBeansProjects\ExcelTest\exread.s

Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
] for j in p.rows]) How can I fix that? I have stuck at this problem. For medium sized files (16K rows and 50 columns) it is fine. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
, May 10, 2017 7:25 PM, Peter Otten <[email protected]> wrote: Mahmood Naderan via Python-list wrote: > Hello, > > The following code which uses openpyxl and numpy, fails to read large > Excel (xlsx) files. The file si 20Mb which contains 100K rows and 50 > colu

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
rows. Mine is about 100k. Currently, the task manager shows about 4GB of ram usage while working with numpy. Regards, Mahmood On Wed, 5/10/17, Peter Otten <[email protected]> wrote: Subject: Re: Out of memory while reading excel file To: pytho

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
On Wed, 5/10/17, Peter Otten <[email protected]> wrote: Subject: Re: Out of memory while reading excel file To: [email protected] Date: Wednesday, May 10, 2017, 6:30 PM Mahmood Naderan via Python-list wrote: > Well actually cells are treated as strings and not integer

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
Hi, I am confused with that. If you say that numpy is not suitable for my case and may have large overhead, what is the alternative then? Do you mean that numpy is a good choice here while we can reduce its overhead? Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
-- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-10 Thread Mahmood Naderan via Python-list
, column=c) arr[r, c] = d.value However, the operation is very slow. I printed row number to see how things are going. It took 2 minutes to add 200 rows and about 10 minutes to add the next 200 rows. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-11 Thread Mahmood Naderan via Python-list
the number of columns in my excel file (p.max_column) The excel file looks like CHR1 11,202,100 NM_198576.3 PASS 3.08932G|B|C -. . . Note that in each row, some cells are '-' or '.' only. I want to read all cells as string. Then I will write the matrix in a file and my main code (java) will process that. I chose openpyxl for reading excel files, because Apache POI (a java package for manipulating excel files) consumes huge memory even for medium files. So my python script only transforms an xlsx file to a txt file keeping the cell positions and formats. Any suggestion? Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Why am I getting a 'sqlite3.OperationalError'?

2017-05-11 Thread Mark Summerfield via Python-list
The ? is indeed for variable substitution, but AFAIK only for field values, not for table names, which is why your first example doesn't work and your second and third examples do work. -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-11 Thread Mahmood Naderan via Python-list
0][1] = 11,232,445 And both are strings. Is that possible? Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-11 Thread Mahmood Naderan via Python-list
second line is empty ("\n") and the third line is the second row of the excel file. Any thought? Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Out of memory while reading excel file

2017-05-11 Thread Mahmood Naderan via Python-list
Thanks a lot for suggestions. It is now solved. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: How to install Python package from source on Windows

2017-05-16 Thread Mark Summerfield via Python-list
may reduce confusion, it won't actually help someone who wants to install a Python package that needs a C compiler. Of course, the error message could give a link to the appropriate compiler. And then the user (who presumably isn't a Windows compiler expert) will if they're really

Re: Finding sentinel text when using a thread pool...

2017-05-20 Thread Christopher Reimer via Python-list
could parse 16 pages at a time. That change would require a bit more work but it would fix some problems that's been nagging me for a while about the parser class. Thank you, Chris Reimer -- https://mail.python.org/mailman/listinfo/python-list

Concatenating files in order

2017-05-23 Thread Mahmood Naderan via Python-list
Hi, There are some text files ending with _chunk_i where 'i' is an integer. For example, XXX_chunk_0 XXX_chunk_1 ... I want to concatenate them in order. Thing is that the total number of files may be variable. Therefore, I can not specify the number in my python script. It has to b

Re: Concatenating files in order

2017-05-23 Thread Mahmood Naderan via Python-list
ould possibly need. >xxx_chunk_01 sorts less than xxx_chunk_10. So, if I write import glob; for f in glob.glob('*chunk*'): print(f) it will print in order. Is that really sorted or it is not guaranteed? Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Concatenating files in order

2017-05-23 Thread Mahmood Naderan via Python-list
hen writing them to the output until there are no more files. Or, if a list of matching files is obtained, the length of the list will also give you the last filename. (But this won't work if there are gaps in the sequence or the numeric format is variable.) -- bartc -- https://

Re: Concatenating files in order

2017-05-25 Thread Mahmood Naderan via Python-list
ith('chunk') and right.isdigit(): filenames[int(right)] = filename sorted_filenames = [ filenames[k] for k in sorted(filenames.keys()) ] It seems that 'filename' should be 'right'. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Concatenating files in order

2017-05-26 Thread Mahmood Naderan via Python-list
. So 'right' is just the numeric suffix - you need 'name' for the open() call. Cheers, Cameron Simpson -- https://mail.python.org/mailman/listinfo/python-list

Re: Verifiably better, validated Enum for Python

2017-05-26 Thread Larry Hudson via Python-list
html -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

embed a package for proper fun script

2017-05-29 Thread Mahmood Naderan via Python-list
Hello, How it is possible to embed a package in my project? I mean, in my python script I have written import openpyxl So, the user may not have installed that package and doesn't understand what is pip! Please let me know the instructions or any document regarding that. Regards, Ma

Re: embed a package for proper fun script

2017-05-30 Thread Mahmood Naderan via Python-list
No idea?... Regards, Mahmood On Tuesday, May 30, 2017 1:06 AM, Mahmood Naderan via Python-list wrote: Hello, How it is possible to embed a package in my project? I mean, in my python script I have written import openpyxl So, the user may not have installed that package and doesn&#

Python not able to find package but it is installed

2017-05-30 Thread Mahmood Naderan via Python-list
Hello, Although I have installed a package via pip on a centos-6.6, python interpreter still says there is no such package! Please see the output below $ python exread2.py input.xlsx tmp/output Traceback (most recent call last): File "/home/mahmood/excetest/exread2.py", line 1

Re: embed a package for proper fun script

2017-05-30 Thread Mahmood Naderan via Python-list
AM, Mahmood Naderan via Python-list > wrote: > > > > Hello, > > How it is possible to embed a package in my project? I mean, in my python > script I have written > > > import openpyxl > > > So, the user may not have installed that packag

Re: Python not able to find package but it is installed

2017-05-30 Thread Mahmood Naderan via Python-list
Well, on rocks there exist multiple pythons. But by default the active is 2.6.6 $ python -V Python 2.6.6 I have to say that the script doesn't modify sys.path. I only use sys.argv[] there I can put all dependent modules in my project folder but that will be dirty. Regards, Mahmood

Re: Python not able to find package but it is installed

2017-05-30 Thread Mahmood Naderan via Python-list
Traceback (most recent call last): File "", line 1, in ImportError: No module named openpyxl But $ find /opt -name openpyxl /opt/rocks/lib/python2.6/site-packages/openpyxl Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: Python not able to find package but it is installed

2017-05-31 Thread Mahmood Naderan via Python-list
Consider this output [root@cluster ~]# pip --version pip 9.0.1 from /opt/rocks/lib/python2.6/site-packages/pip-9.0.1-py2.6.egg (python 2.6) [root@cluster ~]# easy_install --version distribute 0.6.10 [root@cluster ~]# find /opt -name python /opt/rocks/lib/graphviz/python /opt/rocks/bin/python

How to make sure the result of Pandas.to_csv does not have non-ASCII code?

2017-05-31 Thread David Shi via Python-list
How to make sure the result of Pandas.to_csv does not have non-ASCII code? Regards, David -- https://mail.python.org/mailman/listinfo/python-list

Re: Is An Element of a Sequence an Object?

2017-06-04 Thread Larry Hudson via Python-list
oint out that a 'character' is NOT a data type in Python, in the same sense as it is in other languages. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

openpyxl reads cell with format

2017-06-05 Thread Mahmood Naderan via Python-list
ps://mail.python.org/mailman/listinfo/python-list

Openpyxl cell format

2017-06-05 Thread Mahmood Naderan via Python-list
ps://mail.python.org/mailman/listinfo/python-list

Re: Openpyxl cell format

2017-06-05 Thread Mahmood Naderan via Python-list
Maybe... But specifically in my case, the excel file is exported from a web page. I think there should be a way to read the content as a pure text. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: openpyxl reads cell with format

2017-06-05 Thread Mahmood Naderan via Python-list
to formatting. Regards, Mahmood -- https://mail.python.org/mailman/listinfo/python-list

Re: openpyxl reads cell with format

2017-06-05 Thread Mahmood Naderan via Python-list
OK thank you very much. As you said, it seems that it is too late for my python script. Regards, Mahmood On Monday, June 5, 2017 10:41 PM, Dennis Lee Bieber wrote: On Mon, 5 Jun 2017 14:46:18 + (UTC), Mahmood Naderan via Python-list declaimed the following: >>if the cell

Re: Error in initialization of IDLE.

2017-06-07 Thread Mohit Soni via Python-list
Sent from Yahoo Mail on Android I have python 3.5.2 installed and recently I installed python 3.6 and after installing the problem seems to occur. Whenever I start IDLE it shows an error message like "IDLE can't create a sub process or windows firewall might be blocking it"

Re: sqlite3 is non-transactional??

2017-06-15 Thread Mark Summerfield via Python-list
dule is useful, personally, I've switched to using APSW which I've found to be extremely reliable and gives much more access to SQLite functionality: https://rogerbinns.github.io/apsw/ -- https://mail.python.org/mailman/listinfo/python-list

Re: sqlite in 2.7 on redhat 6

2017-06-15 Thread Mark Summerfield via Python-list
On Thursday, June 15, 2017 at 1:47:00 PM UTC+1, [email protected] wrote: > I am trying to use sqlite > > $ python2.7 > Python 2.7.10 (default, Feb 22 2016, 12:13:36) > [GCC 4.4.7 20120313 (Red Hat 4.4.7-16)] on linux2 > Type "help", "copyright", "

course

2017-06-19 Thread Val Krem via Python-list
Hi all, Is there on line course in Python? I am looking for a level between beginner and intermediate. I would appreciate if you could suggest me? Thank you. -- https://mail.python.org/mailman/listinfo/python-list

Syntax error for simple script

2017-06-26 Thread Ben S. via Python-list
Sorry for this newbie question: I installed Python v3.6.1 on win 7. Afterwards I tried to execute the following simple python script from webpage http://www.pythonforbeginners.com/code-s...me-script/: Python Code: from datetime import datetime now = datetime.now() mm = str(now.month) dd

"Python launcher" required to run *.py scripts on Windows?

2017-06-26 Thread Ben S. via Python-list
As I observed v3.6.1 installs (on Windows 7) in addition to the core python engine a second program "Python Launcher". As far as I read this component seems to be not necessary since it only aims to facilitate the handling with *.py scripts on Windows. When I always call Python s

Check Python version from inside script? Run Pythons script in v2 compatibility mode?

2017-07-06 Thread Ben S. via Python-list
Can I somehow check from inside a Python script if the executing Python engine is major version v2 or v3? I am thinking about a code similar to if (os.python-majorversion<3) print hello else print (hello) Additional question: Is there a way to execute a python script with v3 python eng

ANN: A new version (0.4.1) of python-gnupg has been released.

2017-07-10 Thread Vinay Sajip via Python-list
A new version of the Python module which wraps GnuPG has been released. What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. See the project website [1] for more information. Brief summary: * Updated message handling logic to no

RE: Users of namedtuple: do you use the _source attribute?

2017-07-17 Thread Dan Strohl via Python-list
I have never used it personally. It always looked interesting, but I never ran into a need to generate the source for it. -Original Message- From: Python-list [mailto:[email protected]] On Behalf Of Steve D'Aprano Sent: Monday, July 17, 2017 9:58

RE: Best way to assert unit test cases with many conditions

2017-07-18 Thread Dan Strohl via Python-list
o the built-in ordering for strings." -- https://mail.python.org/mailman/listinfo/python-list

Issues with Python

2017-07-30 Thread Ode Idoko via Python-list
Hi, I am new to Python and though I have been able to download the 3.6 version on my laptop , I still have issues with the syntax. While writing a program to execute, it will display syntax error with different shades of color usually green or yellow. What can I do about this? How do I know

Question

2017-07-31 Thread Sonja Williams via Python-list
Good Day, I have decided to learn more about programming so I picked up the book Beginning Programming by Matt Telles. After following the directions verbatim and going to the Python site to download the latest version 3, which is what the book recommended, I keep getting the following

Code for addition

2017-08-04 Thread Ode Idoko via Python-list
Can anyone help with the python code that can add 101, 102, 103...2033 please? As I said before, I'm new to python and need assistance in this regard. Thanks for always assisting. Sent from my iPhone -- https://mail.python.org/mailman/listinfo/python-list

Re: A question on modification of a list via a function invocation

2017-08-14 Thread Larry Hudson via Python-list
some ascii graphics. (Well, not ascii, but utf-8 box-drawing characters — I hope they come through ok. And, of curse, it won't display properly with a proportional font.) The left side is the program lines, and the right side tries to show the way Python implements the name binding to th

Re: A question on modification of a list via a function invocation

2017-08-15 Thread Larry Hudson via Python-list
s the program lines, and the right side tries to show the way Python implements the name binding to the data in memory. (But I abbreviated the long assignment line, alist[0],alist[1],alist[2]=3,6,9 to ) Program line Variable bound to memory === Initial assignment ===

Re: A question on modification of a list via a function invocation

2017-08-17 Thread Larry Hudson via Python-list
tremely clear-cut in comparison to Python, isn't it? Anyway, while any new user of a programming language certainly can be expected to take good efforts to learn a lot of new stuffs, I suppose it's good for any practical programming language to minimize the cases of surprises for those th

Re: A question on modification of a list via a function invocation

2017-08-17 Thread Larry Hudson via Python-list
confusion, Chris. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
Greetings, I have Python 3.6 script on Windows to scrape comment history from a website. It's currently set up this way: Requestor (threads) -> list -> Parser (threads) -> queue -> CVSWriter (single thread) It takes 15 minutes to process ~11,000 comments. When I replace

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
BeautifulSoup may not be thread-safe. I've never had a problem with threads storing the output into a queue. Using a queue (random order) instead of a list (sequential order) to feed pages for the input is making it wonky. Chris R. -- https://mail.python.org/mailman/listinfo/python-list

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
in at different times for the parser worker threads to get for processing. Similar situation with a list but I sort the list before giving it to the parser, so all the items are in sequential order and fed to the parser one at time. Chris R. -- https://mail.python.org/mailman/listinfo/python-list

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
20 read_threads requesting and putting pages into the output queue that is the input_queue for the parser. My soup_threads can get items from the queue, but BeautifulSoup doesn't do anything after that. Chris R. -- https://mail.python.org/mailman/listinfo/python-list

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
list, I'm using a for loop to input items into the parser. If I'm using a queue, I'm using worker threads to put or get items. The item is still the same whether in a list or a queue. Chris R. -- https://mail.python.org/mailman/listinfo/python-list

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
ris R. -- https://mail.python.org/mailman/listinfo/python-list

Is there tested Python code for parsing N-Triples?

2017-08-31 Thread David Shi via Python-list
Is there tested Python code for parsing N-Triples? Looking forward to hearing from you. Regards, David -- https://mail.python.org/mailman/listinfo/python-list

Exponential Smoothing program

2017-08-31 Thread Ode Idoko via Python-list
I am running a master degree programme and very new to programming including python. I have been given a project to write a python program on exponential smoothing of some selected stocks. The program should user the user to input alpha, display the graph of the original data and "smo

rdflib, N-Triples and Pandas

2017-09-01 Thread David Shi via Python-list
How best to use rdflib to parse N-Triples files and turn them into Pandas tables? Looking forward to hearing from you. Regards, David -- https://mail.python.org/mailman/listinfo/python-list

Select data in N-Triples

2017-09-01 Thread David Shi via Python-list
thing like "Baginton E04009817". Then, put the name and code into corresponding cells in 2 columns. Maybe, the solution is to find ways to select those lines having rdf-schema#label Is there a good example? Regards, David -- https://mail.python.org/mailman/listinfo/python-list

Re: Best Practice Virtual Environment

2024-10-08 Thread Left Right via Python-list
ecksums and signatures (by default): so, if the package being installed was updated w/o version update, to pip it's going to be the same package. Not just that, for some packages pip has to resort to building them from source, in which case nobody can guarantee the end result. Insecurity

Re: Correct syntax for pathological re.search()

2024-10-08 Thread Karsten Hilbert via Python-list
Am Tue, Oct 08, 2024 at 08:07:04PM +0100 schrieb MRAB via Python-list: > >unwanted_tex = '\sout{' > >if unwanted_tex not in line: do_something_with_libreoffice() > > > That should be: > > unwanted_tex = r'\sout{' Hm. Python 3.11.2 (mai

Re: Correct syntax for pathological re.search()

2024-10-08 Thread Alan Bawden via Python-list
Karsten Hilbert writes: Python 3.11.2 (main, Aug 26 2024, 07:20:54) [GCC 12.2.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> tex = '\sout{' >>>

Re: Correct syntax for pathological re.search()

2024-10-08 Thread Jon Ribbens via Python-list
those things, and instead do: from pathlib import Path path = Path(r'C:\Windows\example') since in a Path the trailing '\' or '/' is unnecessary. Which leaves very few remaining uses for a raw-string with a trailing '\'... -- https://mail.python.org/mailman/listinfo/python-list

Re: Correct syntax for pathological re.search()

2024-10-08 Thread Karsten Hilbert via Python-list
Am Mon, Oct 07, 2024 at 08:35:32AM -0500 schrieb Michael F. Stemper via Python-list: > I'm trying to discard lines that include the string "\sout{" (which is TeX, > for > those who are curious. I have tried: > if not re.search("\sout{", line): > if no

Signing off

2024-10-08 Thread AVI GROSS via Python-list
Just a final brief note. I am leaving the python community so don't worry that anything happened to me. I have a disagreement with the direction some people are taking with the python community that is my issue and it that probably will not bother most people. I have lots of other inte

RE: Correct syntax for pathological re.search()

2024-10-12 Thread AVI GROSS via Python-list
. -Original Message- From: Python-list On Behalf Of Peter J. Holzer via Python-list Sent: Saturday, October 12, 2024 7:00 AM To: [email protected] Subject: Re: Correct syntax for pathological re.search() On 2024-10-11 17:13:07 -0400, AVI GROSS via Python-list wrote: > Is there some util

Re: Correct syntax for pathological re.search()

2024-10-12 Thread Thomas Passin via Python-list
On 10/11/2024 8:37 PM, MRAB via Python-list wrote: On 2024-10-11 22:13, AVI GROSS via Python-list wrote: Is there some utility function out there that can be called to show what the regular expression you typed in will look like by the time it is ready to be used? Obviously, life is not that

Re: Correct syntax for pathological re.search()

2024-10-12 Thread Thomas Passin via Python-list
On 10/12/2024 6:59 AM, Peter J. Holzer via Python-list wrote: On 2024-10-11 17:13:07 -0400, AVI GROSS via Python-list wrote: Is there some utility function out there that can be called to show what the regular expression you typed in will look like by the time it is ready to be used? I assume

Re: Correct syntax for pathological re.search()

2024-10-09 Thread Karsten Hilbert via Python-list
Am Tue, Oct 08, 2024 at 04:59:48PM -0400 schrieb Alan Bawden via Python-list: > Karsten Hilbert writes: > > Python 3.11.2 (main, Aug 26 2024, 07:20:54) [GCC 12.2.0] on linux >Type "help", "copyright", "credits" or "license

[RELEASE] Python 3.13.0 (final) released

2024-10-07 Thread Thomas Wouters via Python-list
After all the shenanigans two weeks ago – everyone discovering nasty little problems in release candidate 2 – the last week was suspiciously quiet, and therefore I can finally say: <https://discuss.python.org/t/python-3-13-0-final-has-been-released/66972#p-196505-python-3130-is-now-availabl

RE: Correct syntax for pathological re.search()

2024-10-11 Thread AVI GROSS via Python-list
cases, ... -Original Message- From: Python-list On Behalf Of Gilmeh Serda via Python-list Sent: Friday, October 11, 2024 10:44 AM To: [email protected] Subject: Re: Correct syntax for pathological re.search() On Mon, 7 Oct 2024 08:35:32 -0500, Michael F. Stemper wrote: > I'

Re: Best Practice Virtual Environment

2024-10-05 Thread Thomas Passin via Python-list
On 10/5/2024 4:27 PM, Ulrich Goebel via Python-list wrote: Hi, I learned to use virtual environments where ever possible, and I learned to pip install the required packages there. That works quite nice at home. Now I come to deploy a Python script on a debian linux server, making it usable

Re: Best Practice Virtual Environment

2024-10-05 Thread Karsten Hilbert via Python-list
Am Sat, Oct 05, 2024 at 10:27:33PM +0200 schrieb Ulrich Goebel via Python-list: > Debian (or even Python3 itself) doesn't allow to pip install required > packages system wide, so I have to use virtual environments even there. But > is it right, that I have to do that for eve

Re: Best Practice Virtual Environment

2024-10-06 Thread Karsten Hilbert via Python-list
Am Sun, Oct 06, 2024 at 12:21:09AM +0200 schrieb Karsten Hilbert via Python-list: > Am Sat, Oct 05, 2024 at 10:27:33PM +0200 schrieb Ulrich Goebel via > Python-list: > > > Debian (or even Python3 itself) doesn't allow to pip install required > > packages system wide

<    54   55   56   57   58   59   60   61   62   63   >