search for: commas

Displaying 20 results from an estimated 2192 matches for "commas".

2007 Dec 03
3
strsplit on comma, with a trailing comma in input
I have a comma-separated data file in which trailing commas sometimes occur. I am using strsplit to extract the data from this file, and it seems great except in cases with trailing comma characters. The example below illustrates. What I'd like is to get a fourth element in the answer, being an empty string just like the second element. Is there a w...
2007 May 11
14
Trailing commas [best practice survey]
I''m sure everyone has read and committed the Puppet Best Practice to memory by now (I joke). One of the things I''ve written in there deals with trailing commas, which I adopted from the way I used to do multiline in Perl, but I''ve noticed that most people don''t tend to do that in Puppet. Should I revise this or should we all start using the trailing commas? <https://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice#syntax-and-f...
2006 Feb 23
3
Decimal comma instead of decimal point (i18n issue)
Hello, What is the easiest way which enables usage of decimal comma "," instead of decimal point (".") . I would like to force all RoR views to display float numbers with comma instead of decimal point and also to allow insertion of float numbers with comma in forms. Thanks in advance, Karel -- Posted via http://www.ruby-forum.com/.
2009 Mar 14
2
gsub and regex to tidy comma-limited values
I am cleaning up comma-limited values, so that only one comma separates each value. Using the example below, as much as I try with regex, I can't remove the last comma. I hope to have a one-liner solution, if possible. gsub("^,*|,*$|(,)*", "\\1", ",,,apple,,orange,,,,,lemon,strawberry,,,,") [1] "apple,orange,lemon,strawberry,"
2012 Jul 23
3
CSV format issues
Dear all, I have some encoding problem which I'm not familiar with. Here is the case : I'm read data files which can have been generated from a computer either with global settings in french or in english. Here is an exemple ouf data file : * English output Time,Value 17,-0.0753953 17.05,-6.352454E-02 * French output. Time,Value 32,-7,183246E-02 32,05,3,469364E-02 In the first
2010 Oct 08
4
function using values separated by a comma
Hello, I have a dataframe (tab separated file) which looks like the example below - two values separated by a comma, and tab separation between each of these. [,1] [,2] [,3] [ ,4] [1,] 0,1 1,3 40,10 0,0 [2,] 20,5 4,2 10,40 10,0 [3,] 0,11 1,2 120,10 0,0 I would like to calculate the percentage of the smallest number separated by the comma by: 1) summing the values e.g. for
2009 Aug 06
2
Re move all punctuations except commas
Dear all, I wanted to remove all punctuations except commas from a string. I used: gsub("[[:punct:]]", "", string) but I don't know how to exclude the commas ",". Anyone would kindly answer my basic question? -- View this message in context: http://www.nabble.com/Remove-all-punctuations-except-commas-tp24845721p24845721...
2014 Dec 09
4
Passing literals with commas to subroutine
Hi, Let's say I do: Set(data=xxx,yyy) Gosub(my-sub,s,1(${data})) My subroutine will only receive "xxx" for ARG1. How can I pass a literal with a comma to a single argument in a subroutine? (The point is: when calling the subroutine I do not know if the variable has a comma or not.) Thanks, Daniel -------------- next part -------------- An HTML attachment was scrubbed... URL:
2002 Mar 13
1
Commas in formatC
formatC() is great for formatting numbers! But it would be even better if it could optionally insert commas (or semicolons), e.g. R> formatC(1234567.89, digits=2, format="f", commas=T) [1] "1,234,567.89" Here's a snippet of code that does that, which could more or less just be inserted into at the end of formatC if any R-core guru were so inclined. "r" is the r...
2017 May 14
0
[PATCH 2/3] Fix ERROR: Macros with complex values should be enclosed in parentheses
Hi Maciej, [auto build test ERROR on net-next/master] [also build test ERROR on v4.12-rc1 next-20170512] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Maciek-Fijalkowski/Fix-ERROR-trailing-statements-should-be-on-next-line/20170515-021304 config: x86_64-acpi-redef (attached as .config) compiler:
2007 Sep 12
7
[Bug 1361] New: ssh should handle leading comma in authentication method list
http://bugzilla.mindrot.org/show_bug.cgi?id=1361 Summary: ssh should handle leading comma in authentication method list Product: Portable OpenSSH Version: 4.7p1 Platform: ix86 OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: ssh AssignedTo: bitbucket at
2007 Sep 24
3
Data manipulations with numbers which are in 'comma' format
...ind a solution... v=data.frame(a=c("1,234","2,345","5,567")) > v a 1 1,234 2 2,345 3 5,567 I need a column 'b', which is just the addition of column 'a' with 5. How do I do it? And, entries in column 'a' are with commas, always. Also, class(v$a)=factor. BR, Shubha [[alternative HTML version deleted]]
2006 Nov 29
3
comma delimiter & comma in text
Hi I have data like 1, A, 24, The Red House 2, A, 25, King's Home, by the Sea ... I'd like to read this in as three variables. I first tried temp <-read.csv(addresses, sep = "," ) it worked but line 2 was broken after King's Home, and by the Sea as placed in another line. and so i eneded up with more number of rows than in the data. when i tried temp
2012 Sep 10
3
How to remove last comma when iterating through hash in erb template
I need to produce a line in a config file in the format x = "ip1,ip2,ip3" I am using the method below to sort the hash before iterating over it. However, as you can see there will always be a final comma which breaks the app that uses this config file. Does anyone know how I could remove the final comma? ipv4_bind_addresses = "<% routes.sort_by {|key, v| key}.each do |key,
2010 Jan 28
2
[LLVMdev] llc generated machine assembly code for NASM
Hello, I am new here. This is my first post. I spent about three days on trying out LLVM by developing a front-end which is able to generate LLVM IR for a subset of C language. I have not applied any optimization pass yet. On linux, it can go all the way through with the system native assemlber and linker to generate executables. And it runs. I ran into problems on Windows since the generated
2004 Aug 06
2
commas are status2.xsl?
in the status2.xsl there seems to be some extra commas ... --snippet of status2.xsl Global,Client:<xsl:value-of select="connections" /> Source: <xsl:value-of select="source_connections" />,,<xsl:value-of select="listeners" />,, <xsl:for-each select="source"> <xsl:value-of select=&quo...
2015 Sep 28
3
Parse Instruction
...se an assembly code that is space-separated and > I am having a bit of problem. > In *ParseInstruction* function, I don't know what is the easiest > way to figure out how many operands a mnemonic expected to have. > In comma-separated assembly code, it just consuming commas (while > (getLexer().is(AsmToken::Comma))) and adds operands, but it's not > the case for space... > > I have a dirty hack, that I manually provide such information > (number of operands) in a function called for example > getMnemonicAcceptInfo and with a f...
2003 Dec 05
1
How to use Sys.setlocale("LC_NUMERIC")?
...quot;. -- How do I separte values in a vector then? For example ylim=c(2.4, 3.5) -> ylim=c(2,4 ? 3,5), not to get a syntax error with the comma-decimal numbers? Workaround: I can set the value before I switch to "cz_CZ". -- And finally, how do I plot it to the postscript device with commas in labels (2,54), but with points in the postcsript commands (0.75 setlinewidth)? I can understand this is a problem of postscript language/interpreter which doesn't use locales, but R's postscript driver should know, it can't use commas in PS-command arguments. Workaround: I can use &...
2015 Sep 28
2
Parse Instruction
...comma-separated. I would like to parse an assembly code that is space-separated and I am having a bit of problem. In *ParseInstruction* function, I don't know what is the easiest way to figure out how many operands a mnemonic expected to have. In comma-separated assembly code, it just consuming commas (while (getLexer().is(AsmToken::Comma))) and adds operands, but it's not the case for space... I have a dirty hack, that I manually provide such information (number of operands) in a function called for example getMnemonicAcceptInfo and with a for loop I parse the operand!! What would you sug...
1999 Mar 31
0
ace () - again
Dear all, I am still trying to find out what goes wrong when I use ace (I get an 'NAs in foreign fuction call (arg3)' but when I go through it with debug there seem no data to be missing). I had some errors (see at end of message) while installing 'acepack'. Do you think it is possible that these lead to the fact, that simple problems run ok but larger problems result in an