977 questions
1
vote
1
answer
153
views
Line Separator Python \r\n
We have an English-Latin dictionary in our hands, that is, a list of words in English and their translations into Latin (there may be several translations) in the form of a file with the following ...
0
votes
1
answer
106
views
How do the meta variables in the following macro expansion work?
I am learning rust macros.
In the part on repetition, the following macro is used to demonstrate how repetitions work:
macro_rules! repeat_two {
($($i:ident)*, $($i2:ident)*) => {
$( ...
-2
votes
2
answers
252
views
How to split columns in a CSV in Power Automate
enter image description here
Hello everyone, you will find in my image a Power Automate flow with the creation of a CSV from a Power BI dataset. Everything works very well except for one small detail. ...
0
votes
1
answer
80
views
csv to dataframe with several delimiters and software bug
I would like to read in a csv-file. Sadly this is created by a buggy software: My header row contains multiple separators ";" and ",". Which wouldn't be a problem if my dataset ...
0
votes
0
answers
125
views
string format a Decimal instance using an underscore as a thousands separator?
I can easily do this for floats using an f-string like this:
x = float(123456789.123456)
print(f"{x:_f}")
prints 123_456_789.123456 exactly as expected.
But if try the same technique for a ...
0
votes
0
answers
46
views
Sqlite3 import csv with CRLF (2 chars) as row separator
I want to import a csv file with TAB column separator and CRLF (2 chars) as row separator.
I use:
.mode ascii
.separator "\t" "\r\n"
to which sqlite3 complains:
Error: multi-...
0
votes
1
answer
74
views
Unexpected Decimal Separator Behavior with CultureInfo in .NET
In the attached images, you can observe that I am explicitly using both InvariantCulture and a new instance of CultureInfo("en-US") when converting a Double to a String:
value.ToString(...
3
votes
3
answers
163
views
R: how to split strings into three columns using tidyr
Here is how one column in my data looks like:
dat <- data.frame(
A = c("M24656811 M24677722 GREEN,SMITH34/M/B", "M24654999 DOE,JANE V37/F/W", "M24333107 DOE,JOHN24/M/B"...
0
votes
0
answers
12
views
How I can split a cell which contains a text to different rows whithout loosing whole sheet format?
enter image description here image from a part of my spread sheet.
how can I divide rows number 35-37 to a single row like 34. In the image for example names and numbers are in wrapped text format but ...
0
votes
1
answer
91
views
Unable to Change Comma to a Dot in Decimals in R [closed]
I have a .csv file that I’m having trouble processing because the numbers use commas for decimals, which causes issues when reading the file in R. Excel interprets commas for decimals, while R uses ...
2
votes
1
answer
116
views
Control {fmt} formatting of nested containers/ranges
If I have a range I can print it with the fmt library, in this way: https://fmt.dev/8.1.0/api.html#ranges-api
#include <fmt/ranges.h>
std::vector<int> t = {1, 2, 3};
// Prints "[1, 2,...
0
votes
1
answer
37
views
Concatenate values with "/" separator in XSLT 1.0
I have XML with product's parameters like colors.
<parameter name='color'>
<value>black</value>
<value>white</value>
</parameter>
I want to output a value ...
2
votes
1
answer
74
views
Django - change form prefix separator
I'm using form prefix to render the same django form twice in the same template and avoid identical fields id's.
When you do so, the separator between the prefix and the field name is '-', I would ...
0
votes
1
answer
62
views
Splitting R string based on multiple criteria (data does not have a simple delineation like spaces or comma to separate by)
I have a dataset where each row is a character string like this (and this is all under one column):
Jacoby BrissettO 206.5-115U 206.5-115Joe BurrowO 243.5-115U 243.5-155.
I want to split this into ...
1
vote
0
answers
170
views
Display a list comma separated taxonomy terms with "and" as final separator in Wordpress
I'm trying to output a list of custom taxonomies on Wordpress where the final separator is an &.
I have three potential taxonomies a post could be in: Category 1, Category 2, and Category 3. Some ...
-1
votes
1
answer
48
views
formating my json output file using python
with open(output_file_path_final, 'w') as f:
json.dump(final, f, separators=(',', ':'))
this is the key lines of my python code and I get output as below,
{"frame.number":[80.0,87.0,...
1
vote
6
answers
103
views
Separating the last number in each line from the letters
I have a long file with provisional SNP IDs and alleles, which looks like this:
14_611646T,C
14_881226CT,C
14_861416.1GGC,GGCGCGCGCG
I would like to separate the last number in each line from the ...
-3
votes
1
answer
89
views
How to get the current decimal/thousand separator for an unknown number
I have to insert into the database a number acquired from various sites for which I don't know what the decimal separator/thousand separator is.
Input numbers that express the value 1000 could be:
1,...
2
votes
2
answers
87
views
Awk : an other way more elegant to do it ? See inside?
I wrote a awk program which give me the result i needed.
Finding any line beginning with 130AB : if the 2nd field contain data, move it on the 9th field
My input file :
130DD2532||1|||1|
130AB00100501|...
0
votes
3
answers
66
views
Pandas read txt file delimiter appears in text
I have a dataset in the shape of a txt file that looks like this:
beer_name: Legbiter
beer_id: 19827
brewery_name: Strangford Lough Brewing Company Ltd
brewery_id: 10093
style: English Pale Ale
abv: 4....
0
votes
2
answers
2k
views
How can I get a GS1 datamatrix code (with separators) to a C# winforms application
I use a barcode scanner to read medecine GS1 datamatrix codes. I need the entire data sequence, including Group Separators to parse the code in order to seek for Application identifiers (AI) and get ...
6
votes
1
answer
1k
views
How to create a menu separator in pystray
I am trying to create a pystray menu separator, but I am having a hard time doing so. I have searched here on SO and in its documentation, which I find super confusing and unhelpful and I even tried ...
0
votes
1
answer
54
views
How to get the custom separator Excel uses in pd.read_csv()
I have several .txt files with data I would like to plot. Since there are so many, I prefer using python to plot these rather than Excel. The .txt files have been generated by German machinery, which ...
0
votes
1
answer
32
views
split a column in a sequential array of names
Good evening community, I want to separate a character column of the separate_wider_delim type into several sequential columns.
"count_id"
"120 987 203 116 77 890 194 88 915 926 1028 ...
1
vote
3
answers
122
views
How can I add separators to lists of numbers? [duplicate]
I'm having an exercise where it told me to print out each person's favourite numbers. When it came to people with more than one number, I couldn't keep the numbers in one line, separated by commas. ...
-1
votes
2
answers
544
views
How to make a vertical text divider, in CSS?
In HTML CSS how to make a vertical divider to separate two sections.
::before and :: after do not work. Any genius trick would be appreciated.
I also tried margins, but they arent as good. Maybe we ...
0
votes
1
answer
2k
views
Is there a way to use the sep="" function with an inputed string
I have been trying to use the separator function with a message that uses the input function, but it seems the that the separator function does not work and it only prints out the inputed phrase. For ...
-1
votes
1
answer
94
views
Print the most frequently occuring letter in a string using AWK [closed]
I have text file
('1', 6310445) [12, 20]_S:0.6:0:ACAAAAAAAAAAA_i_V
('1', 17704109) [12, 31]_S:0.387:0:CCCCCCCCCCCC_i_V
('1', 18922274) [8, 22]_S:0.364:0:AAAAAAAA_i_V
('1', 22750694) [8, 19]_S:0.421:0:...
1
vote
1
answer
44
views
Read in data from web (xml format) but then need to separate fields
I am reading in a dataset from this link:
url = "https://www.bis.doc.gov/dpl/dpl.txt"
This is how I have read it in (if I read it in as a csv I get the Forbidden error -> hence the use ...
0
votes
0
answers
2k
views
Rainbow CSV fails to determine the separator automatically: property not allowed
I had a problem of Rainbow CSV failing to determine the true separator in a file (pipe) and setting it to a wrong one (comma).
From Rainbow CSV I learned that to make it determine a separator ...
1
vote
2
answers
78
views
Sepereate string into table by variable number of whitespaces
I have some data that get imported to R like that (character string):
> dput(my_data)
c("S Leistung Sub Text Ergebnis Einheit Normal Auffällig Katalog Datum Zeit Kommentar ",
" ...
0
votes
2
answers
30
views
How to create new pandas columns from a pandas data frame column content
I have the following pandas dataframe:
import pandas as pd
import numpy as np
ds1 = {'Name':["Juan Pablo Montoya","Jose Hiero","Martin Vasquez"], "Comments" : [&...
0
votes
0
answers
63
views
merge columns with variable separator
I need to merge two numerical columns in my dataframe as a new column, with 0's as separators. However, the number of 0's is dependent upon the number of digits in the second column. So, what I want ...
1
vote
2
answers
2k
views
How to use dot as decimal separator when the current culture is Greek
I would like to change the decimal separator in a Blazor .NET 7 multi-language site when the selected language is Greek.
The numbers are by default changed to comma separated when I change the ...
0
votes
1
answer
157
views
Trying to join array of strings, such that they occur in next line using FTL template
Here is array of strings, myArray = ["green","blue","red"], I want to display each value in next line on html page
"green"
"blue"
"red"
I ...
1
vote
2
answers
44
views
Creating a string with separators from a list of numbers using Python3
I have a list of numbers:
list1 = [1, 2, 3, 4]
I would like to create a string as follows:
Contains([saleID],"1") OR
Contains([saleID],"2") OR
Contains([saleID],"3") OR
...
1
vote
1
answer
477
views
Making a default style for a menu item separator in WPF, within the scope of a particular menu
I'm trying to change the way a separator appears in my WPF context-menu. The context menu has its own default style, which is already successfully applying a style to all of its menu items.
<Style ...
1
vote
1
answer
212
views
Read delimited file with separator and quote as the same quote character - "
I have a CSV file where the separator is "
However, there are also several text variables in the file which have " " around the text "example".
Therefore, read.csv does not ...
0
votes
1
answer
440
views
How to change the decimal separator in a ggsurvplot?
I would like to change the decimal separator of all the numbers (risk table, x and y axis, as well as p-value) in a Kaplan Meier curve from "." to "," (e.g. from 3.1415 to 3,1415). ...
-2
votes
2
answers
294
views
How to set consistent decimal separators in R data frame? [duplicate]
Some columns in my data frame have ',' and some have '.' as decimal separator.
DateTime a b c
2000-01-01 00:30:00 3,4 6,1 9.5
2000-01-01 00:45:00 3,5 6,8 7.4
I would like to ...
0
votes
1
answer
605
views
How to have a space thousand separator on pyplot graphs
I am plotting graphs but the values on my y-axis goes up to 175 000. Of course, python and pyplot does not use thousand separators by default. The graphs have to go into an article subject to ...
3
votes
4
answers
74
views
How to separate strings in a list, multiplied by a number
I need to take a list, multiply every item by 4 and separate them by coma.
My code is:
conc = ['0.05 ml : 25 ml', '0.05 ml : 37.5 ml', '0.05 ml : 50 ml', '0.05 ml : 62.5 ml', '0.05 ml : 75 ml']
...
0
votes
1
answer
86
views
Change separator when exporting CSV with VBA
How can I change the separator that a CSV file is exported with in VBA without changing regional settings etc?
The macro should be used across multiple computers and different users, I don't want to ...
1
vote
1
answer
39
views
Split the texts in the array into words Python
Is there a way to split the text of each input in an array to words with a separator?
Example Input
tag_attribute = ['Content_ExportDate','Controller_SoftwareRevision','DataType_Owner']
With the ...
-2
votes
1
answer
288
views
WPF - Create ComBox with multiple separators
I want to make a ComboBox with 0-N Separators
I was able to do this with CompositeCollection like so
<ComboBox.ItemsSource>
<CompositeCollection>
<CollectionContainer Collection =...
2
votes
1
answer
85
views
mysql uses "." as a value separator in match(ip_list) against(string), with "," 'string' also present
When processing ip addresses, and comparing them, something goes wrong, and it finds almost all the data from the database.
Query:
SELECT * FROM superbans WHERE NOT uuid=? AND (MATCH(ip_list) AGAINST(?...
0
votes
1
answer
596
views
ItemSeparatorComponent React Native
So, i'm using a separator in a flatlist. I linked the separator to a logging function that logs the key of each item in the flatlist. When i reload the app, the first 10 items are logged, then the ...
2
votes
6
answers
372
views
Separating a column with multiple different entries with tidyr
I am trying to split up one column in a data frame that shows the period active(s) for several artists/ bands into two columns (start_of_career, end_of_career). The variable class is character. I ...
0
votes
1
answer
354
views
pd.read_csv sep ";" not working. tricky dataset
I tried different stack overflow solutions using pd.read_csv for this file.
When I use Excel to text to and use ";" as delimiter in Excel, it gives exactly the output I need.
data:
'Balance ...
0
votes
1
answer
36
views
using split() with paragraphs and assigning values to variables
I have a .txt file of the following but each value starting on the next line
229
flowers
7
2.99
456
bows
3
19.99
I originally coded for them as if they were separated by commas instead of starting on ...