Questions tagged [lines-of-code]

The number of code lines. Can be used as a metric.

The number of code lines. Generally, a set of metrics are placed to estimate the quality of coding. lines-of-code is one of the metrics used to determine for example if a class is too long or too short. This metric is not an accurate one and is most of the time used with other metrics such as the number of methods, number of static fields, etc.

170 questions
0
votes
1 answer

Estimate lines of code in BBC website

Does anyone have an estimation for lines of code in BBC News website? (and estimating strategy) http://www.bbc.co.uk/news/ I could not find any estimation methodologies. The closest answer was all about counting lines of code for local projects, but…
PYVITW
  • 1
0
votes
1 answer

Is there a max. limit for lines of code in Aptana 3?

i work with Aptana 3.0.6. Today i opend a CSS file with 10302 lines of code and i can only make two or three click's and than Aptana freezes vor 5 seconds (or more). Is there a limit for lines of code? How can I fix the problem? Thanks!
Alex
  • 1
0
votes
1 answer

Ruby on Rails Validates Method Structure

I have a fairly simple ruby syntax question (and a couple other clarifications), and I can't figure it out for the life of me. The context is I have pretty common model class subclassing ActiveRecord::Base, and I am utilizing validates. I believe…
Benjamin
  • 1,832
  • 1
  • 17
  • 27
0
votes
2 answers

`git push` without faking how much lines I have actually written

Well, situation is that I need to know how LoC (lines of code) I have written so far. It's easy because GitHub.com has 'Stats & Graphs' - 'Impact' section where it's all clearly visible. The problem is that I need to add, lets say, jQuery. I'm not…
daGrevis
  • 21,014
  • 37
  • 100
  • 139
0
votes
4 answers

Identify LOC for each file in iOS project - ObjectiveC based application development

Is there tool that will give me a detailed report on number lines each file/class in project has? I tried CLOC. All that I get is that the project level and that is nice to start with. I want a detailed drill down on each class. Do we have any open…
Krishnan Sriram
  • 5,037
  • 5
  • 21
  • 31
0
votes
1 answer

Counting conditional statements in Eclipse

I want to count the occurrence of conditional statements like if, else if, for, case. Using normal eclipse search may give results which includes "if" from a comments. Is there any plugin to do this job ?
0
votes
1 answer

Problems with loc function in python, doesn't find a label taht is in my dataframe

I have an issue with using the 'loc' function in Python. I would like to extract a specific row from my dataframe 'df', which contains movie titles along with their respective information. The problem is that when I use 'df.loc['movie title']', I…
0
votes
0 answers

how to use np.where with .loc

1 ,2 3 is a Month (Miesiac) and "123","222",.... is Price(cena) cena_dict = { 1 : "123", 2 : "222", 3 : "2131231" } data = { "Zrodlo" : ["A","B","B"], "Wartosc" : [100,200,300], "MWh" : [10,20,10], "Miesiac" : [1,2,5] } first way -…
Adii
  • 37
  • 3
0
votes
2 answers

How to replace NaN values with the correspondent month and hour mean value

I'm trying to replace the NaN values from a DataFrame with the correspondent month and hour mean value of this DataFrame. So let's say I have a DataFrame with generic measures where, randomly, there is no measure in some rows and columns. This…
Endo
  • 3
  • 1
0
votes
1 answer

traverse a list of dictionaries and store them into a separate column

https://github.com/ajayvd/DOUBT_SO/blob/main/doubt.csv The above link contains the data frame and it contains 2 columns response_value & response_errors & The response_errors contains the value in list of dictionaries . problem statement so here i…
lifo
  • 19
  • 5
0
votes
1 answer

AND condition and strict equality in loc

I need to match the payment of invoices in the DocN column of df1 with the data in the TXT column in df2. Print the document (DocN) + the amount (DocSum) and the details of the corresponding payment (DocP, Date) in accordance with the matching…
user534280
  • 11
  • 1
0
votes
0 answers

Check against 2 columns and if true replace value in one

dataframe[(dataframe['Column1']=="Value1") and (dataframe[dataframe['Column2'].str.contains('partial string',case=False)])]='new value to be placed instead' the above should be looking for 2 conditions... one full match and one partial and if its…
ARML
  • 1
  • 1
0
votes
1 answer

Pandas: set column value based on other columns: Filtering Data and changing column values

New python programmer here. Sample data is shown below. I have a dataframe that has < 1,000 rows. That df came from reading an Excel workbook. The "Store" column has multiple kinds of data: 1) a store number, 2) Bank charges, 3) Other kinds of…
Fred
  • 1
  • 3
0
votes
1 answer

Search for LOV columns in dataframe and replace with codes using other dataframe

Imagine I have a dirty dataframe of employees with their ID, and Contract related information per country. Some columns of this dataframe are LOV columns (depending on the country, some columns are LOV for just one country, others some or all of…
Paulo Cortez
  • 609
  • 4
  • 10
0
votes
1 answer

Python: Formating totals to showcase different formulas per row rather than just the total sums

I have a large dataset with different rows that I created using formulas and the grouped by function # Create new column "iCPI" grouped_sums['iCPI'] = grouped_sums['Budget Delivered'] / grouped_sums['Incr Conversions'] # Create new column "iCVR"…